Sleep and wake
Sleeps when idle or always running: idle timeouts, why something sleeps and how it wakes.
Workspaces and services that nobody uses go to sleep, and wake on the next visit. While asleep they use no CPU or memory, so they do not count against your team's quota. Their files, env vars, secrets and settings are kept.
Sleeps when idle and Always running
Every workspace, and every service with pods, has an availability:
| Availability | Behaviour |
|---|---|
Sleeps when idle (on-demand) | Sleeps after the idle timeout without use, wakes on the next visit |
Always running (always) | Keeps running and holds its resources around the clock |
The idle timeout is 60 minutes unless your installation sets another default. A workspace sets its own under
Workspace settings → Sleep after (minutes); a service sets
availability and idleTimeoutMinutes in harthelm.yml. Both take 1 to
1440 minutes. Without them, a service takes the availability of its plan.
The IDE and the services sleep independently: a service sleeps when it gets no requests, the IDE when nobody uses it.
What counts as use
The IDE stays awake while any of these is true. Workspace settings → Power shows which one keeps it awake right now:
- someone works in the IDE or in a terminal (a tab left open without input stops counting after 3 hours),
- a prepare or test stage runs,
- a command started with
hart execruns, - a keep-awake window is open,
- connections to the workspace are open.
A service stays awake while requests reach it. A service also stays awake while another awake service needs it.
A long build in a terminal that you no longer look at does not keep the workspace awake. Open a keep-awake window for it; see Keep a workspace awake.
How things wake
- Open the workspace in the console, or run
hart ws open: the IDE wakes. - Visit a dev URL or a custom domain: the router wakes the service behind the path, and every service it needs, and holds the request until they are ready. The page waits a few seconds.
- Run wakes the landscape's sleeping services.
- Wake it explicitly: Wake in the Run panel or the power list, or
hart ws wake.
Waking usually takes a few seconds. Each replica runs its steps again from the start, as after any pod start.
hart ws wake --wait waits until every target the wake started is ready (with --target, only those), names them,
and fails when one of them cannot wake. Against a server older than 1.0.3, it waits only for
the IDE.
Stopped services
A service that was never run, or that someone stopped, is stopped, not asleep. A wake does not start it, and its dev URL says "This service is stopped". When your installation switches nodes off at night, a stopped service is put to sleep with the rest so that nothing waits for a node all night, but the console and the API still show it as stopped. The next Run or Start wakes it first and then starts it. Nothing wakes it in the morning.
Why something sleeps
The workspace's sleep screen says why it went to sleep:
| Reason | What happened |
|---|---|
| Nobody used it | The idle timeout passed |
| Put to sleep by hand | Someone clicked Put to sleep now |
| Node out of service for the night | Your installation switches some nodes off at night; the workspace wakes after that time |
| Node drained | An administrator drained the node it ran on |
| Being restored | It is being restored from an archive |
When waking is refused
| You see | Why |
|---|---|
| "There is no room to wake it right now" | The cluster has no free capacity. Harthelm asks again by itself; try later or ask your administrator |
| "This workspace sleeps until …" | Its nodes are switched off until then |
| "Waking is paused" | The platform has paused waking workspaces |
| "The team's quota does not fit this" | The team's awake workspaces and services already use the quota. Put something else to sleep or ask a team admin |