Skip to content
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

deprecate KubernetesClient.customResource #3386

Closed
shawkins opened this issue Aug 6, 2021 · 4 comments
Closed

deprecate KubernetesClient.customResource #3386

shawkins opened this issue Aug 6, 2021 · 4 comments
Milestone

Comments

@shawkins
Copy link
Contributor

shawkins commented Aug 6, 2021

Given the support for genericKubernetesResources, customResources should now be deprecated.

@manusa
Copy link
Member

manusa commented Aug 10, 2021

I'm not sure I would fully agree on this one in case it refers to the class CustomResource and not the method KubernetesClient#customResources. (I recall having discussed this elsewhere, but I can't find the reference now.)

CustomResources are treated differently by Kubernetes and have specific areas of the API dedicated to them. They have specific validation, subresources, etc. which might not be shared by the rest of the K8s resources. Through the CustomResource class, we're also enforcing users to adopt best practices such as using Spec and Status fields.

Regarding the DSL method(s), they are already deprecated. We should update any documentation, example, quickstart, etc. to use the new methods and remove these methods in a future release after a prudent period.

@shawkins
Copy link
Contributor Author

Regarding the DSL method(s), they are already deprecated. We should update any documentation, example, quickstart, etc. to use the new methods and remove these methods in a future release after a prudent period.

Sorry, I wasn't specific - KubernetesClient.customResource

RawCustomResourceOperationsImpl customResource(CustomResourceDefinitionContext customResourceDefinition);
is not yet deprecated, it's what I'm referring to here.

@manusa
Copy link
Member

manusa commented Aug 10, 2021

There's a subtle difference with RawCustomResourceX and GenericKubernetesResource. I'm all in for deprecating, but I would wait for feedback before completely removing it.

@manusa
Copy link
Member

manusa commented Aug 12, 2021

Fixed by #3395

@manusa manusa closed this as completed Aug 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants