Skip to content

Can not create a snapshot when using PVC for workspaces #14159

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

Closed
Tracked by #7901
gtsiolis opened this issue Oct 25, 2022 · 11 comments
Closed
Tracked by #7901

Can not create a snapshot when using PVC for workspaces #14159

gtsiolis opened this issue Oct 25, 2022 · 11 comments
Assignees
Labels
feature: pvc / snapshots feature: snapshots team: workspace Issue belongs to the Workspace team type: bug Something isn't working

Comments

@gtsiolis
Copy link
Contributor

Bug description

Although PVC rollout is only internal so far, there's an issue that prevents users from creating a snapshot when using PVC for workspaces. When users try to create a snapshot, they get an error notification inside VS Code Browser. ❗

Moreover, the PVC feature seems to be enabled regardless if the project setting is enabled. 💭

See relevant docs on workspace snapshots and relevant discussion (internal). Cc @jenting @sagor999 @kylos101

VS Code notification Project settings
Screenshot 2022-10-25 at 1 28 10 PM Screenshot 2022-10-25 at 1 42 37 PM

Steps to reproduce

  1. Be part of the feature flag that enables PVC for your account.
  2. Open a workspace for any repository or project.
  3. Try creating a snapshot from the command palette.
  4. Notice that snapshot creation fails, and you get an error notification.

Workspace affected

No response

Expected behavior

No response

Example repository

No response

Anything else?

No response

@sagor999
Copy link
Contributor

@gtsiolis how does this feature work? :)
When it is done, does it show you a link to download your snapshot tar file? Is it used for anything else?

@kylos101
Copy link
Contributor

When it is done, does it show you a link to download your snapshot tar file?

👋 @sagor999 it shows you a link to start a workspace like this, which can be used to create many regular workspaces. In other words, having the URL to the snapshot means you can start a workspace from the Snapshot's backup context...entirely avoiding the original Git or prebuild or backup context. Some people use this to take 'point in time' backups of their workspaces, so that they have something to fall back to.

@gtsiolis
Copy link
Contributor Author

@sagor999 In addition to what @kylos101 described, here's also how this feature is described in the relevant docs section on how to create a snapshot:

VS Code Browser: To create a snapshot, run "Gitpod: Share Workspace Snapshot" from the hamburger menu at the top left of VS Code, from the Gitpod menu at the bottom, or via the VS Code command palette. Once you execute the command, the snapshot is taken and the URL is shown in a dialog.

@jenting
Copy link
Contributor

jenting commented Nov 2, 2022

@sagor999 Do you need help on this issue? If yes, feel free to talk with me.

@sagor999
Copy link
Contributor

sagor999 commented Nov 2, 2022

@jenting no, thank you. I was OOO until now, but I should have workspace part implemented today. 🙏

@sagor999
Copy link
Contributor

sagor999 commented Nov 2, 2022

@geropl adding this to WebApp inbox.
I implemented Workspace related changes to make snapshotting work when workspace is using PVC.
Now I need your help to implement webapp side of changes.
Two changes are required:

  1. Call TakeSnapshot for ws-manager client for workspace that needs to be snapshotted (I believe this might not to be changed by reading webapp code, but I could be wrong. wsman TakeSnapshot now checks if workspace is PVC enabled and creates snapshot using PVC if so, and as a result returns volume snapshot name as Url. This is similar to how volume snapshots are stored in DB already for PVC enabled workspaces).
  2. Change how we check when snapshot is ready. Currently webapp directly checks GCS if the tar file was uploaded. Now instead webapp needs to check if workspace is PVC enabled, then call ws-manager new RPC that I added: CheckVolumeSnapshotReady by passing Url as snapshotID into it, and it will return true or false if snapshot is ready for use or not).

Please feel free to add your PR on top of this PR: #14374

Would be amazing if you can prioritize this, as it blocks PVC rollout currently.

🙏

@kylos101 👀

@geropl geropl moved this to Scheduled in 🍎 WebApp Team Nov 3, 2022
@geropl
Copy link
Member

geropl commented Nov 3, 2022

@sagor999 Scheduled for next week 👍

@svenefftinge svenefftinge self-assigned this Nov 8, 2022
@svenefftinge svenefftinge moved this from Scheduled to In Validation in 🍎 WebApp Team Nov 8, 2022
@svenefftinge svenefftinge moved this from In Validation to In Progress in 🍎 WebApp Team Nov 8, 2022
@svenefftinge svenefftinge moved this from In Progress to In Validation in 🍎 WebApp Team Nov 8, 2022
@geropl geropl moved this from In Validation to In Progress in 🍎 WebApp Team Nov 14, 2022
@geropl
Copy link
Member

geropl commented Nov 18, 2022

@kylos101 My understanding is that we can delay the work here until we are clear on how PVC is moved forward with. Correct? 🤔

@kylos101
Copy link
Contributor

@geropl 💯 yes

@sagor999
Copy link
Contributor

Removed from workspace project for now as we are rethinking our PVC approach.

@svenefftinge
Copy link
Member

we've decided to discontinue/roll-back the PVC work as is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature: pvc / snapshots feature: snapshots team: workspace Issue belongs to the Workspace team type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants