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

OpenAPI validation for Katib CRs - prevent invalid specs #1170

Closed
jlewi opened this issue Apr 25, 2020 · 6 comments
Closed

OpenAPI validation for Katib CRs - prevent invalid specs #1170

jlewi opened this issue Apr 25, 2020 · 6 comments

Comments

@jlewi
Copy link
Contributor

jlewi commented Apr 25, 2020

/kind feature

I'm getting customer reports that invalid Experiment specs lead to experiments being stuck.

This is a common failure mode with custom resources; if the resource spec is invalid the resource will get created but when the controller tries to parse it the parsing will fail.

I think the new/recommended way of handling this might be to use OpenAPI schema validation in the CRD.
https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#specifying-a-structural-schema

It looks like Katib CRDs might be missing this
https://github.com/kubeflow/manifests/blob/master/katib/katib-crds/base/experiment-crd.yaml

@issue-label-bot
Copy link

Issue Label Bot is not confident enough to auto-label this issue.
See dashboard for more details.

@johnugeorge
Copy link
Member

@jlewi Can you explain more on the invalid experiment specs that get created? Katib already has a validating webhook

@gaocegege
Copy link
Member

Kubebuilder supports generating OpenAPI schema for CRDs. I think we can support it in the next API version. (v1beta1, maybe)

@jlewi
Copy link
Contributor Author

jlewi commented Apr 29, 2020

I believe the customer was passing names which were too long for the experiments and this caused the controller to stop working.

@stale
Copy link

stale bot commented Nov 24, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale
Copy link

stale bot commented Dec 19, 2020

This issue has been automatically closed because it has not had recent activity. Please comment "/reopen" to reopen it.

@stale stale bot closed this as completed Dec 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants