-
Notifications
You must be signed in to change notification settings - Fork 886
Autostop: bump deadline if workspace hits autostart time #2028
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
Comments
The desired behavior makes a lot more sense to me, too. |
I agree with the desired behavior. Thinking of this, I wrote some (probably incorrect) pseudo-logic around it in the RFC, that you should only be able to extend your workspace deadline up to the next auto-on time, assuming that at the scheduled auto-on, your deadline would refresh.
Revisiting that, I don't know if it's helpful or not (the |
Hmm why don't limit Auto-Off to |
@johnstcn how complex is this to do? I don't have an idea of it, but if it's trivial it might be nice to add to the EE milestone. |
I would hesitate to call this "trivial", but I think enough people have found it annoying for me to try to get it in anyhow! |
We haven't gotten suggestions for this, so I'm closing for now! |
I'm in support of making this change. Sometimes I restart the workspace in the evening (say 8pm) and with a normal schedule of 9:30am + 14h, this would result in autostop happening at 10am, at which point the workspace will be stopped when I try to login in the morning. |
@deansheather is working on changes related to our scheduling behavior to avoid this. Basically, workspaces will only stop during "quiet hours" to prevent workspaces from stopping at inconvenient times, such as right before an autostart. Going to close in favor of that |
@bpmct can you link to more details on how "quiet hours" are defined? |
Yep: #8117 |
Quiet hours does not interact with regular TTL (only the "restart requirement") so this needs to be reopened. I think we should just change the activity bumping code to be like: newDeadline := time.Now().Add(ttl)
if newDeadline.After(nextAutoStartTime) {
newDeadline = nextAutoStartTime.Add(ttl)
} |
We also need to change the initial calculation for deadline to have this extra clause too, in |
@deansheather - is this still on your plate |
I had a PR for this but it went stale due to the offsite and my vacation. I don't think it's super high priority though TBH |
Bumping this and re-opened the PR. We should bring it into this sprint. |
A couple of our folks have noticed this quirk as well. Not having this breaks the assumption that your workspace will be up from |
Sounds good to me. |
We fixed this a while back! |
What is your suggestion?
We may want to change autostop behaviour to bump the workspace deadline when it hits the scheduled autostart time.
Current Behaviour
Given:
When:
Then:
Desired Behaviour
When:
Then:
Why do you want this feature?
Some folks were surprised that their workspaces got shut down at the configured time.
Are there any workarounds to get this functionality today?
coder bump my-workspace however-many-hours-you-need
Are you interested in submitting a PR for this?
Yes
The text was updated successfully, but these errors were encountered: