-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[Dashboard] Show warning when unsupported Devfile features used #21873
Comments
I've added the label for you... if this is for sprint/next do we want to mark it P1 and assign it to an |
Thanks @nickboldt :) Sorry for the slow reply, but yes I believe the |
my comment in the DWO issue - devfile/devworkspace-operator#984 (comment) |
@ibuziuk I've tried creating ( |
@akurinnoy yeah, we should not block the devworkspace creation/startup but should notify the user that some of the fields defined in the spec would not work since those are not supported by DWO - https://github.com/devfile/devworkspace-operator/blob/main/docs/unsupported-devfile-api.adoc |
Is your enhancement related to a problem? Please describe
There are features in the Devfile spec that are currently unsupported by the DevWorkspace-Operator (and consequently, by Che).
devfile/devworkspace-operator#989 adds support for providing a webhook warning when applying a devworkspace that contains unsupported features, however this warning is not yet taken into account by the Che Dashboard.
Describe the solution you'd like
When a warning is provided by the DevWorkspace-Operator about unsupported features being present in the devworkspace, the Che-Dashboard should display this warning and ask the user if they wish to continue using the Devfile, or resort to using the default devfile, similar to the UX implemented in #20738.
When the webhook warning is returned, the kubernetes API HTTP response body has the following format:
Devworkspace:
Response Body (see warning at very end):
The warning is outside the outermost JSON braces, and will always begin with
Warning:
.Edit: I got the above response body by doing a
kubectl apply -f ... -v=9
. However, checking the Kubernetes Webhook docs shows that the warning should be present within its own JSON key/value element, like the following:It also mentions that the response should contain HTTP Warning headers with a warning code of 299.
Here is a longer example of an unsupported feature warning message, though the requirement for displaying the warning in the dashboard should just be to display the Warning in its entirety (no modification of the message should be necessary):
Describe alternatives you've considered
Currently, the only way to see this warning is by directly
oc/kubectl apply
'ing the devworkspace to the cluster.Additional context
The DWO issue and suggested UX
The text was updated successfully, but these errors were encountered: