-
Notifications
You must be signed in to change notification settings - Fork 40k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for 3rd party objects to kubectl #18835
Conversation
Labelling this PR as size/L |
GCE e2e build/test failed for commit 199926c05554a22edfd73d3199c325cea4c128ae. |
199926c
to
9cacb46
Compare
GCE e2e build/test failed for commit 9cacb46f0bc2b3d296849ea6fd2262f2d844739b. |
9cacb46
to
ade3e4e
Compare
Resources map[string]unversioned.GroupVersionKind | ||
} | ||
|
||
func interfacesFor(version string) (*meta.VersionInterfaces, error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see this used anywhere.
Second commit mostly lgtm. Not familiar enough with master/apiserver to comment on the first one. |
GCE e2e build/test failed for commit ade3e4e6b77c6ca483698502ed1983fee76fb70d. |
b36e0bd
to
eb88094
Compare
@jlowdermilk comments addressed. second commit is the only one for review, the first commit is covered in: #18484 |
lgtm |
clientVersions = append(clientVersions, registered.RegisteredGroupVersions[ix]) | ||
} | ||
// Add in any third party group/version resources | ||
list, err := gvClient.ThirdPartyResources(api.NamespaceDefault).List(api.ListOptions{}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
forbidden's from this API request should be handled gracefully. I don't think I'd expect the whole method to fail.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done.
eb88094
to
c06eaf9
Compare
return priorityRESTMapper, api.Scheme | ||
// return outputRESTMapper, api.Scheme |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you remove these two lines?
GCE e2e build/test passed for commit 6d4fbe9fe5d6d52d870365822c5377603aa8f8eb. |
@caesarxuchao comments addressed, please take another look. Thanks! |
GCE e2e build/test passed for commit 79f0b45df212671647863f138ba851f4e0d6f3f9. |
GCE e2e build/test passed for commit be6c5b3. |
@caesarxuchao comments addressed and all green. Any chance for an LGTM? this one is a bear to keep in sync. |
Thanks @brendandburns. LGTM. We can incrementally fix the left issues. |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit be6c5b3. |
cfg, err := clientConfig.ClientConfig() | ||
CheckErr(err) | ||
cmdApiVersion := unversioned.GroupVersion{} | ||
if cfg.GroupVersion != nil { | ||
cmdApiVersion = *cfg.GroupVersion | ||
} | ||
if discoverDynamicAPIs { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cc @krousey I think you'd be interested in this. This is building REST mapper (with the exisiting RESTMapper struct) based on discovery results.
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit be6c5b3. |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit be6c5b3. |
Automatic merge from submit-queue |
@deads2k @jlowdermilk
Instructions for playing around with this:
Run an apiserver with third party resources turned on (
--runtime-config=extensions/v1beta1=true,extensions/v1beta1/thirdpartyresources=true
)Then you should be able to:
Once that is done, you should be able to:
After this PR, you can do:
etc.