Skip to content

[server] Remove obsolete (Theia) User Storage Resource #18377

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

Merged
merged 2 commits into from
Aug 1, 2023

Conversation

AlexTugarev
Copy link
Member

@AlexTugarev AlexTugarev commented Jul 28, 2023

Description

Summary generated by Copilot

🤖 Generated by Copilot at a67a742

This pull request removes all the code and dependencies related to the user storage resources feature from the Gitpod server, protocol, and database components. User storage resources were a deprecated feature that allowed users to allocate disk space for their workspaces. This cleanup simplifies the code base and reduces the complexity of the Gitpod services.

Related Issue(s)

Fixes #

How to test

Documentation

Preview status

Gitpod was successfully deployed to your preview environment.

Build Options

Build
  • /werft with-werft
    Run the build with werft instead of GHA
  • leeway-no-cache
  • /werft no-test
    Run Leeway with --dont-test
Publish
  • /werft publish-to-npm
  • /werft publish-to-jb-marketplace
Installer
  • analytics=segment
  • with-dedicated-emulation
  • workspace-feature-flags
    Add desired feature flags to the end of the line above, space separated
Preview Environment
  • /werft with-local-preview
    If enabled this will build install/preview
  • /werft with-preview
  • /werft with-large-vm
  • /werft with-gce-vm
    If enabled this will create the environment on GCE infra
  • with-integration-tests=all
    Valid options are all, workspace, webapp, ide, jetbrains, vscode, ssh
  • with-monitoring

/hold

@AlexTugarev
Copy link
Member Author

@akosyakov, does it make sense to remove this Theia legacy?
I've checked with DB and last entry is from 2021-09-05 23:42:43.741844000.

@AlexTugarev AlexTugarev marked this pull request as ready for review July 28, 2023 06:51
@AlexTugarev AlexTugarev requested a review from a team as a code owner July 28, 2023 06:51
@geropl
Copy link
Member

geropl commented Jul 28, 2023

Taking a tour now... 👀

) {
resourceRev = fromTheiaRev;
}
const resourceRev = (await this.db.getResource(req.user.id, resourceKey, ref, collection))?.rev;
if (!resourceRev) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

!resourceRev || resourceRev === fromTheiaRev ?

some clients can already cache it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

although it should fail like that anyway after trying to access content storage

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be awesome, if you'd double-check this area. I don't want to break users.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jeanp413 could you double check please, on first glance it looks alright

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yep looks good

@akosyakov
Copy link
Member

@akosyakov, does it make sense to remove this Theia legacy?
I've checked with DB and last entry is from 2021-09-05 23:42:43.741844000.

It is more important whether are users still migrating. It seems like 1% still does [1]. But we discussed it in the past and were inclined to remove [2], so should be alright.

@akosyakov akosyakov requested a review from jeanp413 July 28, 2023 08:00
Copy link
Member

@svenefftinge svenefftinge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/workspace/gitpod/components/gitpod-db/src/typeorm/entity/db-user-storage-resource.ts is no longer needed as well

Copy link
Member

@svenefftinge svenefftinge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are also the following two files that need to be updated:
/workspace/gitpod/components/gitpod-protocol/go/gitpod-service.go
/workspace/gitpod/components/gitpod-protocol/go/mock.go

not sure if they are manually edited or generated) Looks like generated but it never works for me so I would usally edit them manually 🤷

@jeanp413
Copy link
Member

jeanp413 commented Jul 29, 2023

/gh run recreate-vm

Comment triggered a workflow run

Started workflow run: 5701264548

  • recreate_vm: true

@AlexTugarev
Copy link
Member Author

/unhold

@roboquat roboquat merged commit 29ace49 into main Aug 1, 2023
@roboquat roboquat deleted the at/rm-theia-user-storage-resource branch August 1, 2023 07:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants