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

When starting a workspace with the same name as an existing one ask users if they wants to replace the pre-existing one #21561

Closed
ibuziuk opened this issue Jul 19, 2022 · 7 comments · Fixed by eclipse-che/che-dashboard#622
Assignees
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. new&noteworthy For new and/or noteworthy issues that deserve a blog post, new docs, or emphasis in release notes severity/P1 Has a major impact to usage or development of the system. sprint/current
Milestone

Comments

@ibuziuk
Copy link
Member

ibuziuk commented Jul 19, 2022

Describe the bug

Getting Started workspace fails to start if there is an existing workspace

Che version

7.50@latest

Steps to reproduce

existing workspace

Expected behavior

exising cpp workspace is started

Runtime

OpenShift

Screenshots

No response

Installation method

OperatorHub

Environment

Linux

Eclipse Che Logs

No response

Additional context

Note Dashboard should reopen any workspace if exists not only Getting Started

Release Notes Text

Previously, when starting a workspace with the same name of an existing one, Che would return an error and users should either manually delete the existing one or rename the new workspace. Now users are asked if they want to re-open the existing one or if they want to replace it with the new workspace.

@ibuziuk ibuziuk added kind/bug Outline of a bug - must adhere to the bug report template. severity/P1 Has a major impact to usage or development of the system. dogfooding area/dashboard labels Jul 19, 2022
@ibuziuk ibuziuk mentioned this issue Jul 19, 2022
51 tasks
@ibuziuk ibuziuk mentioned this issue Aug 9, 2022
67 tasks
@ibuziuk
Copy link
Member Author

ibuziuk commented Aug 17, 2022

the issue is really annoying and we should backport the fix in 3.2

@ibuziuk ibuziuk changed the title Getting Started workspace fails to start if there is exsiting workspace workspace fails to start if there is exsiting workspace with such a name Aug 17, 2022
@l0rd
Copy link
Contributor

l0rd commented Aug 17, 2022

Ok but we should not restart the workspace because it has the same name: it may have the same name but refer to another branch (i.e. you have just reviewed a PR) or even be a completely different git repository. How are we going to figure out if that's the same workspace or a different one?

@svor
Copy link
Contributor

svor commented Aug 18, 2022

Can we just create a new workspace but with another name (maybe adding some suffix)

@l0rd
Copy link
Contributor

l0rd commented Aug 18, 2022

Can we just create a new workspace but with another name (maybe adding some suffix)

Right but that's what generateName, in the DevWorkspace spec, is supposed to do. If the problem here is with samples I think we can use generateName instead of name when generating the DevWorkspace.

I think samples are easy because we start from a DevWorkspace.yaml. @ibuziuk the problem here is with a sample (i.e. if fails the second time you try a sample) right?

I can create a distinct issues for non-samples but in general I would ask the user if he wants to restart the existing workspace or replace it with the new one. To create multiple workspace using the same devfile it's recommended to leave the metadata.name empty in the devfile.yaml or use the new query parameter. But again, I think that's a distinct issue.

@ibuziuk ibuziuk mentioned this issue Aug 24, 2022
82 tasks
@ibuziuk ibuziuk added sprint/current severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code. severity/P1 Has a major impact to usage or development of the system. and removed severity/P1 Has a major impact to usage or development of the system. severity/blocker Causes system to crash and be non-recoverable or prevents Che developers from working on Che code. labels Aug 25, 2022
@l0rd l0rd changed the title workspace fails to start if there is exsiting workspace with such a name Workspace fails to start if there is exsiting workspace with such a name Sep 2, 2022
@l0rd l0rd changed the title Workspace fails to start if there is exsiting workspace with such a name Workspace sample fails to start if the sample has already been created Sep 2, 2022
@l0rd
Copy link
Contributor

l0rd commented Sep 2, 2022

I can create a distinct issues for non-samples but in general I would ask the user if he wants to restart the existing workspace or replace it with the new one. To create multiple workspace using the same devfile it's recommended to leave the metadata.name empty in the devfile.yaml or use the new query parameter. But again, I think that's a distinct issue.

@akurinnoy I have changed the title here because it looks that the issue is related to samples only. If that's not the case let's discuss it because the solution is not clear.

@l0rd l0rd changed the title Workspace sample fails to start if the sample has already been created When starting a workspace with the same name as an existing one ask users if they wants to replace the pre-existing one Sep 15, 2022
@l0rd l0rd added new&noteworthy For new and/or noteworthy issues that deserve a blog post, new docs, or emphasis in release notes status/release-notes-review-needed Issues that needs to be reviewed by the doc team for the Release Notes wording labels Sep 15, 2022
@max-cx
Copy link

max-cx commented Dec 16, 2022

Sync'd with Red Hat JIRA https://issues.redhat.com/browse/CRW-3640

@max-cx max-cx removed the status/release-notes-review-needed Issues that needs to be reviewed by the doc team for the Release Notes wording label Jan 12, 2023
@nickboldt nickboldt added this to the 7.56 milestone Jan 14, 2023
@devstudio-release
Copy link

sync'd to Red Hat JIRA https://issues.redhat.com/browse/CRW-3850

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dashboard kind/bug Outline of a bug - must adhere to the bug report template. new&noteworthy For new and/or noteworthy issues that deserve a blog post, new docs, or emphasis in release notes severity/P1 Has a major impact to usage or development of the system. sprint/current
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants