- Notifications
You must be signed in to change notification settings - Fork928
Addreason
field for workspace builds#2438
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
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.
I really like this approach! Nice n' simple 😎
Uh oh!
There was an error while loading.Please reload this page.
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.
LG. Minor nit
Uh oh!
There was an error while loading.Please reload this page.
johnstcn left a comment• edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
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! I Just a couple small issues.
Transition: trans, | ||
JobID: newProvisionerJob.ID, | ||
err = store.InTx(func(db database.Store) error { |
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.
This is already in one big transaction, see line 80 -- since we're already in a tx, this ends up being a no-op
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.
Oh TIL. I didn't see that@AbhineetJain
AbhineetJainJun 17, 2022 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
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.
Thanks@johnstcn. This was also the reason the tests were failing.
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.
Issue:#2468
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
778b819
to4802eaf
Compare4802eaf
toc5b9aac
CompareThere 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.
Nice work!
Uh oh!
There was an error while loading.Please reload this page.
This PR adds a new
reason
field for workspace builds to indicate the reason for its initiation. The following values are supported:initiator
,autostart
,autostop
.The following combinations can arise:
In case of
Reason.Autostart
andReason.Autostop
, we ignore the initiator field when displaying it in the UI, and use the initiator field for the other case - the member could be admin too (or whoever the user may possibly be sharing workspaces with).Subtasks