Start typing to search.

API Reference

Executor heartbeat

View Markdown
POST /api/executors/heartbeat

Renewed by each executor on a fixed cadence. Reports active run IDs so the control plane can renew their run leases and detect zombies. The response returns cancelRunIds — run IDs the executor still believes are live but whose DB rows are already terminal (e.g. failed by the run reaper during a partition). Executors serving a single control plane fence (cancel) those tasks; multi-CP executors ignore the list to avoid cross-CP run-ID collisions.

Operation IDexecutorHeartbeat

Authentication

  • ExecutorKeyAuth·http bearer·Shared executor secret (ENVOY_EXECUTOR_KEY). Used by internal executor-to-control-plane routes (registration, heartbeat, completion/log callbacks).·Internal executor authentication; use the shared executor key.

Request body

This request body is required.

Content typeapplication/json

requestobject
5 properties
urlstringrequired

Executor base URL (matches runs.executor_id).

activeTasksintegerrequired

Number of tasks currently executing on the executor.

maxConcurrentinteger

Optional updated concurrency capacity.

labelsobject

Optional updated label set used for dispatch selection.

Additional properties
valuestring | boolean | number
One of
One of 1string
One of 2boolean
One of 3number
runIdsarray<integer>

Run IDs the executor currently has in flight. Omit (or send a non-array) for legacy executors — the control plane then renews every non-terminal run owned by url. An empty array means the executor is idle (nothing to renew).

Array items
iteminteger

Success response body

200Heartbeat acknowledged; lease renewal attempted and fencing list returned.

Heartbeat acknowledged; lease renewal attempted and fencing list returned.

Content typeapplication/json

responseobject
2 properties
okboolean
cancelRunIdsarray<integer>

Run IDs the executor reports as live but whose DB rows are already terminal — fence (cancel) these.

Array items
iteminteger

Error responses

404Resource not found

Resource not found

Content typeapplication/json

responseobject
2 properties
errorstring
messagestring
Example response
{
  "error": "NOT_FOUND",
  "message": "Resource not found"
}