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

Listen on instance updates of a running prebuild #10646

Merged
merged 1 commit into from
Jun 15, 2022
Merged

Conversation

AlexTugarev
Copy link
Member

@AlexTugarev AlexTugarev commented Jun 14, 2022

... even if you are not the workspace owner.

Follow up to #10357

How to test

  • clone https://gitlab.com/alex736/gitpod-large-image into your account
  • create a project for it using the preview environment from this PR
  • push a change which modifies a) the Dockerfile and/or b) the init script in the .gitpod.yml file
  • quickly switch to the project's page and start a workspace when you see the prebuild being started
  • now you should see the "Prebuild in Progress" page
  • depending on the time "configured" in the Dockerfile of the repo (modification a) you should eventually see the transition to the following workspace creation pages

Fixes #8195

NONE

@AlexTugarev
Copy link
Member Author

AlexTugarev commented Jun 14, 2022

/werft run

👍 started the job as gitpod-build-at-followup-10357.2
(with .werft/ from main)

@AlexTugarev AlexTugarev marked this pull request as ready for review June 15, 2022 07:41
@AlexTugarev AlexTugarev requested a review from a team June 15, 2022 07:41
@github-actions github-actions bot added the team: webapp Issue belongs to the WebApp team label Jun 15, 2022
@AlexTugarev AlexTugarev mentioned this pull request Jun 15, 2022
11 tasks
@geropl geropl self-assigned this Jun 15, 2022
//
// The owner's client connection is automatically registered to listen on instance updates.
// For the remaining client connections which would handle `createWorkspace` and end up here, it
// also would be reasonable to listen on the instance updates of a running prebuild, or image build.
Copy link
Member

@geropl geropl Jun 15, 2022

Choose a reason for hiding this comment

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

nit: Would love to see these additional lines as comment:

We need to be forwarded the WorkspaceInstanceUpdates in the frontend, because we do not have any other means to reliably learn about the status about image builds, yet. Once we have those, we should remove this.

@geropl
Copy link
Member

geropl commented Jun 15, 2022

@AlexTugarev How to best test this to see that it really fixes #8195? 🤔

@werft-gitpod-dev-com
Copy link

started the job as gitpod-build-at-followup-10357.3 because the annotations in the pull request description changed
(with .werft/ from main)

@AlexTugarev
Copy link
Member Author

AlexTugarev commented Jun 15, 2022

@geropl, the how to test is copied over from #10357 ☝🏻

The main difference is to use a second account to start the workspace from, right after triggering a prebuild configured for the first user.

@AlexTugarev AlexTugarev reopened this Jun 15, 2022
@geropl
Copy link
Member

geropl commented Jun 15, 2022

Started testing, btw! 👍 Still waiting for the build to finish..

@AlexTugarev
Copy link
Member Author

In addition to that, the second user's websocket connection should receive instance updates.

Copy link
Member

@geropl geropl left a comment

Choose a reason for hiding this comment

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

Awesome, fixed it! 🚀

/hold in case you want to address this comment right away, but leave it up to you 👍

@geropl
Copy link
Member

geropl commented Jun 15, 2022

In addition to that, the second user's websocket connection should receive instance updates.

Jup, it did! 👍

@werft-gitpod-dev-com
Copy link

started the job as gitpod-build-at-followup-10357.4 because the annotations in the pull request description changed
(with .werft/ from main)

even if you are not the workspace owner.
@AlexTugarev
Copy link
Member Author

/hold cancel

@roboquat roboquat merged commit 769c7b2 into main Jun 15, 2022
@roboquat roboquat deleted the at/followup-10357 branch June 15, 2022 10:14
@roboquat roboquat added deployed: webapp Meta team change is running in production deployed Change is completely running in production labels Jun 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
deployed: webapp Meta team change is running in production deployed Change is completely running in production release-note size/M team: webapp Issue belongs to the WebApp team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[prebuild] Not starting workspace once the prebuild is done
3 participants