-
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
add generateName
to devfile metadata
#14157
Conversation
wsmaster/che-core-api-workspace/src/main/resources/schema/devfile.json
Outdated
Show resolved
Hide resolved
@@ -14,6 +14,7 @@ | |||
apiVersion: 1.0.0 | |||
metadata: | |||
name: petclinic-dev-environment |
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.
is it valid to have both name and generateName ?
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.
it is valid, but 'generateName' is basically ignored in that case.
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
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.
Looks good to me
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
ci-test |
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has failed:
|
Signed-off-by: Michal Vala <mvala@redhat.com>
Signed-off-by: Michal Vala <mvala@redhat.com>
Co-Authored-By: Florent BENOIT <fbenoit@redhat.com> Signed-off-by: Michal Vala <mvala@redhat.com>
Signed-off-by: Michal Vala <mvala@redhat.com>
@sparkoo: PR check has been failed because it uses Jenkinsfile now, which has been merged in master tonight. So, you need to take changes from master. |
ci-test |
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
Results of automated E2E tests of Eclipse Che Multiuser on OCP: |
generateName
to devfile metadatagenerateName
to devfile metadata
@sparkoo Added WIP in PR title to avoid occasional merge before 7.0.0 |
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.
LGTM
Please take a look my inlined comments
...-core-api-model/src/main/java/org/eclipse/che/api/core/model/workspace/devfile/Metadata.java
Show resolved
Hide resolved
...-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/WorkspaceManager.java
Show resolved
Hide resolved
...-core-api-workspace/src/main/java/org/eclipse/che/api/workspace/server/WorkspaceManager.java
Outdated
Show resolved
Hide resolved
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
Signed-off-by: Michal Vala <mvala@redhat.com>
E2E Happy path tests of Eclipse Che Single User on K8S (minikube v1.1.1) has been successful:
|
@@ -569,6 +575,26 @@ private WorkspaceImpl doCreateWorkspace( | |||
return workspace; | |||
} | |||
|
|||
/** | |||
* If 'generateName' is defined and 'name' is not, we generate name using 'generateName' as a |
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 we use generateName
all the time if it is defined ?
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.
kubernetes takes name
in that case and we follow kubernetes approach here.
generateName
to devfile metadatagenerateName
to devfile metadata
What does this PR do?
Adds
generateName
field to devfile. The field is used just in create workspace phase, where it's transformed into regular devfilename
. ThegenerateName
is not persisted nor used in later phases like workspace startup, update, etc.Current implementation follows Kubernetes with
[generateName]YYYYY
, whereY
is random[a-z0-9]
character.What issues does this PR fix or reference?
#13794 (see comment #13794 (comment))
Release Notes
Docs PR
redhat-developer/devfile#46
redhat-developer/devfile#48