Skip to content

Epic: User Configurable Workspace Timeouts (CLI command + user preference) #9038

@svenefftinge

Description

@svenefftinge

Press Release

Gitpod users can now set any timeout up to 24 hours using the command line, or with a native integration in their favourite editors! To try out this feature, simply type: gp timeout set 1h in any running workspace to extend the workspace inactivity timeout of that workspace. To set your global user preference timeout, got to your use preferences and set the value that you want to apply for all future timeouts. Additionally, we've also made the editor timeout configuration optional, meaning that if you don't want a Gitpod workspace to timeout when you close your editor, you can now set

External Questions

Does this work for free users? No, currently only users on a paid plan can extend timeouts.
Is the timeout respected / guarenteed? No. A workspace has a maximum continuous session time of 36 hours.
Do timeout settings apply to running workspaces? TBC
Can you set an admin preference for timeouts? Not currently. This is something we plan to introduce as an organisation policy in the future.

Internal Questions

Why have a 24hr timeout limit? 24 hours is somewhat arbitrary, and we want to learn what users do with this. But, also the 24hr is based around a few infrastructure constraints. We have an undocumented 36 hour workspace session limit, that we need for doing workspace deployments, to allow us to upgrade workspaces. There are also some tokens within the workspace scoped to 24 hours that might break if a workspace runs longer than 24 hours (@akosyakov mentioned this - the supervisor token, which is revoked on workspace stop, renews on restart but doesn't refresh).

Context

Gitpod timeouts have historically been optimised mostly for cost reduction, to relieve users from any anxiety about leaving workspaces running forever and therefore creating unnecessary cost. Since Gitpod is ephemeral we want to encourage users to start new workspaces and manage the scaling of these workspaces to not incur unnecessary cost. As Gitpod moves towards a usage-based pricing model #9036 there is opportunity to review how Gitpod handles timeouts, giving more power to the user to decide what timeout configuration works best for them.

Currently, timeouts are fixed to 30min resp. 60min (+ 3h boost) for unlimited users. In some cases, however, there is a trade-off being made between the usability of Gitpod workspaces and cost management (through timeouts) as some users have use-cases where they want to have Gitpod workspaces open for longer, whereas other users would like to keep workspaces running, and are less cost conscious.

Use Cases

  1. User is using an unsupported client without heart-beating (e.g. JetBrains Fleet)
  2. User is running long-running tasks in workspaces and needs to leave workspace running (e.g data tasks)
  3. When there is friction in re-setting up a closed workspace (e.g. re-setting up SSH commands, etc)
  4. General convenience when going away from your computer for some time and returning

Acceptance Criteria (Implementation)

Acceptance Criteria (Measurement)

  • What values do users set timeouts to? Do they need 24 hours? (e.g. understand use cases for timeouts)
  • Are timeouts respected? e.g. users setting X timeout on a long running workspace that is then closed.

In scope

Out of scope

Related issues

Depends on:

Potential fixes

Solutions for flexible timeout options:

  • Setting a default per-user - e.g. allowing users to change the default workspace timeout
  • Setting a schedule - e.g. allowing users to configure a schedule where workspaces do not timeout. [1]
  • Extending timeouts arbitrarily - e.g. a command in workspace (similar to 3h boost)
  • Global default - e.g. Self-Hosted installs able to change the global default (current default is 30min).
  • API for timeout - For custom integrations, such as educational products that use Gitpod + want workspaces to timeout for cost reasons, but want to sleep / wake them programatically.
Original description

Summary

Allow users to change the default workspace timeout and extend timeouts arbitrarily. Self-Hosted installs should be able to change the global default (usually 30min).

Context

The automatic timeouts are a convenience feature, that should relieve users from any anxiety about leaving workspaces running forever and therefore creating unnecessary cost.
Currently, it is fixed to 30min resp. 60min (+ 3h boost) for unlimited users.
Once usage-based pricing exists we can allow users to freely choose their timeouts.
We should do this on two levels:

  • setting a default per user
  • manual command in workspace (similar to 3h boost)

Value

Depending on behaviour patterns and use cases, a different timeout might make sense.

Acceptance Criteria

The new feature (user setting and workspace action) needs to be shipped to SaaS and Self-Hosted release.
The change has been communiticated.

Measurement

The new feature is used by active users. Send events on use.

Growth Area

expansion

Persona(s)

Active users

Metadata

Metadata

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions