Events & Logs
Structured task logs, webhooks, and the autoscaler.
Structured task logs, webhooks, and the autoscaler.
Durable, per-job structured log rows in shared storage. Beyond diagnostics they
carry streaming partial results: a running task writes partials at level
"result" and a consumer polls them live (see the
streaming guide).
| Method | Description |
|---|---|
writeTaskLog(jobId, taskName, level, message) | Append a log row. An overload adds a String extra payload. |
getTaskLogs(jobId) → List<TaskLog> | Every row for a job, oldest first. |
getTaskLogsAfter(jobId, afterId) → List<TaskLog> | Rows after a cursor id — poll this to stream new partials without rescanning. |
queryTaskLogs(taskName, level, sinceMs, limit) → List<TaskLog> | Cross-job query by task and level (e.g. every "result" line since a timestamp). |
WebhookManager.attach(flexiq) registers outcome webhooks, and
Scaler.start(flexiq, ScalerOptions.onPort(9090)) serves a queue-depth
endpoint for external autoscalers — both build on this client.