Skip to content

istioctl describe: fixes, test case, remove deprecated code#20169

Closed
esnible wants to merge 13 commits intoistio:masterfrom
esnible:fix-describe
Closed

istioctl describe: fixes, test case, remove deprecated code#20169
esnible wants to merge 13 commits intoistio:masterfrom
esnible:fix-describe

Conversation

@esnible
Copy link
Copy Markdown
Contributor

@esnible esnible commented Jan 14, 2020

Fixes istioctl x describe recent bug
Adds an integration test for istioctl x describe
Remove deprecated istioctl get put delete create set-context

Fixes #18972
Fixes #20157

@esnible esnible requested review from ayj and nmittler January 14, 2020 18:27
@esnible esnible requested review from a team as code owners January 14, 2020 18:27
@googlebot googlebot added the cla: yes Set by the Google CLA bot to indicate the author of a PR has signed the Google CLA. label Jan 14, 2020
@istio-testing istio-testing added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jan 14, 2020
Copy link
Copy Markdown
Member

@howardjohn howardjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixes #20160

framework.NewTest(t).
RunParallel(func(ctx framework.TestContext) {

ctx.NewSubTest("ISTIOCTL").
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
ctx.NewSubTest("ISTIOCTL").
ctx.NewSubTest("istioctl").

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

actually just remove the subtest entirely


podID, err := getPodID(a)
if err != nil {
t.Fatalf("Could not get Pod ID: %v", err)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs to be the same thing that was passed to the func the tests runs in (ctx in this case)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand the comment. What is the problem?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See the test failure: testing.go:864: test executed panic(nil) or runtime.Goexit: subtest may have called FailNow on a parent test

You can't use the parents t, its not a valid use of the go testing library

@esnible
Copy link
Copy Markdown
Contributor Author

esnible commented Jan 14, 2020

@howardjohn Test question. The integration test works locally, and works for the pilot integration tests, but fails for integ-new-install-k8s-tests_istio because for that test istioctl x describe believes the pods are not PERMISSIVE, but DISABLE.

https://prow.istio.io/view/gcs/istio-prow/pr-logs/pull/istio_istio/20169/integ-new-install-k8s-tests_istio/5229

I am not sure what to do. I don't want to relax the output comparison because if it changes I want this test to pick it up. I don't know how to recreate locally the options used for integ-new-install-k8s-tests_istio, or why Pilot's /debug/authenticationz?proxyID will return different values when I use it.

@howardjohn
Copy link
Copy Markdown
Member

@esnible that test is just running istioctl manifest apply, not sure why it would be different? At this point (I thought, but this makes me think I am wrong) its almost entirely redundant from the pilot-k8s-test, we should probably clean it up - I am curious why its different here

@ayj
Copy link
Copy Markdown
Contributor

ayj commented Jan 14, 2020

LGTM overall. Will add final approval after John's test comments are addressed.

@esnible esnible added the do-not-merge/work-in-progress Block merging of a PR because it isn't ready yet. label Jan 15, 2020
@esnible
Copy link
Copy Markdown
Contributor Author

esnible commented Jan 15, 2020

/test integ-pilot-k8s-tests_istio

@esnible esnible removed the request for review from nmittler January 15, 2020 20:27
@esnible
Copy link
Copy Markdown
Contributor Author

esnible commented Jan 15, 2020

@ayj I have completed the things @howardjohn asked for. Please review now.

@esnible esnible removed the do-not-merge/work-in-progress Block merging of a PR because it isn't ready yet. label Jan 15, 2020
@howardjohn
Copy link
Copy Markdown
Member

This is the only reason we have a fair amount of legacy junk in Pilot, will be useful to get rid of this

@howardjohn
Copy link
Copy Markdown
Member

@nmittler can you take a look? Then we can clean up the config store a bit

@esnible esnible requested review from a team January 19, 2020 15:18
@esnible esnible added the do-not-merge/hold Block automatic merging of a PR. label Jan 19, 2020
@esnible esnible removed the do-not-merge/hold Block automatic merging of a PR. label Jan 19, 2020
pull bot pushed a commit to sniperking1234/istio that referenced this pull request Jan 19, 2020
)

* istioctl describe: fixes, test case, remove deprecated code

* Remove unneeded subtest structure

* Remove unnecessary change in describe

* Match describe output by regexp, not string

* Additional output to test the tests

* Keep constructor signature

* Fix compilation problem

* Look for Envoy config metadata in Istio 1.5.x format

* 'make format'

* Ran 'gen'
pull bot pushed a commit to sniperking1234/istio that referenced this pull request Jan 19, 2020
)

* istioctl describe: fixes, test case, remove deprecated code

* Remove unneeded subtest structure

* Remove unnecessary change in describe

* Match describe output by regexp, not string

* Additional output to test the tests

* Keep constructor signature

* Fix compilation problem

* Look for Envoy config metadata in Istio 1.5.x format

* 'make format'

* Ran 'gen'
pull bot pushed a commit to sniperking1234/istio that referenced this pull request Jan 19, 2020
)

* istioctl describe: fixes, test case, remove deprecated code

* Remove unneeded subtest structure

* Remove unnecessary change in describe

* Match describe output by regexp, not string

* Additional output to test the tests

* Keep constructor signature

* Fix compilation problem

* Look for Envoy config metadata in Istio 1.5.x format

* 'make format'

* Ran 'gen'
@esnible
Copy link
Copy Markdown
Contributor Author

esnible commented Jan 21, 2020

@howardjohn What is needed to proceed on this?

@howardjohn
Copy link
Copy Markdown
Member

@esnible I am pretty sure the code changes were merged but somehow the PR is open, so Ithink we can just close this?

@howardjohn
Copy link
Copy Markdown
Member

Just verified the changes are in, so I recommend just closing

@nmittler
Copy link
Copy Markdown
Contributor

@esnible @howardjohn do we know how these changes got committed? Maybe someone force pushed from the command-line to the master branch accidentally? I wouldn't expect that would even be possible.

@howardjohn
Copy link
Copy Markdown
Member

howardjohn commented Jan 21, 2020 via email

@fejta
Copy link
Copy Markdown

fejta commented Jan 21, 2020

Please rebase this PR. It looks like github only merged some of the commits (3 of 13)?

@esnible esnible added the do-not-merge/hold Block automatic merging of a PR. label Jan 21, 2020
@esnible
Copy link
Copy Markdown
Contributor Author

esnible commented Jan 21, 2020

Closing because this is already merged!

926a1bf#diff-f4fb5eb2363cca54308accde8f31be9c is the commit.

@fejta
Copy link
Copy Markdown

fejta commented Feb 18, 2020

thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/user experience cla: yes Set by the Google CLA bot to indicate the author of a PR has signed the Google CLA. do-not-merge/hold Block automatic merging of a PR. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"istioctl x describe pod/svc" no longer shows destination rules and virtual service config Create istioctl describe integration test

7 participants