Skip to content

Add worker cancellation controls#63

Open
ianhodge wants to merge 1 commit intoih/worker-observability-metricsfrom
ih/worker-cancellation-controls
Open

Add worker cancellation controls#63
ianhodge wants to merge 1 commit intoih/worker-observability-metricsfrom
ih/worker-cancellation-controls

Conversation

@ianhodge
Copy link
Copy Markdown
Member

@ianhodge ianhodge commented May 1, 2026

Summary

  • handle task_cancellation WebSocket control messages and cancel matching active task contexts
  • report cancelled tasks with terminal task_state=CANCELLED while preserving the existing completion flow
  • record cancellation metrics and lifecycle events for server-initiated and shutdown cancellations
  • harden Docker/direct cancellation behavior and update README cancellation metric docs

Validation

  • go test ./internal/metrics ./internal/worker
  • go test ./...
  • helm template oz-agent-worker charts/oz-agent-worker --set image.tag=test --set worker.workerId=test-worker --set warp.apiKeySecret.create=true --set warp.apiKeySecret.value=dummy --set metrics.enabled=true
  • git diff --check

Co-Authored-By: Oz oz-agent@warp.dev

Copy link
Copy Markdown
Member Author

ianhodge commented May 1, 2026

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@ianhodge ianhodge force-pushed the ih/worker-cancellation-controls branch from f7e2782 to 8c0bcfd Compare May 1, 2026 22:40
@ianhodge ianhodge force-pushed the ih/worker-observability-metrics branch from d76db19 to 7b988b5 Compare May 1, 2026 22:40
@ianhodge ianhodge changed the title Add worker cancellation controls Co-Authored-By: Oz <oz-agent@warp.dev> Add worker cancellation controls May 1, 2026
@ianhodge ianhodge changed the title Add worker cancellation controls Add worker cancellation controls May 1, 2026
Co-Authored-By: Oz <oz-agent@warp.dev>
@ianhodge ianhodge force-pushed the ih/worker-cancellation-controls branch from 8c0bcfd to fa8a8ba Compare May 1, 2026 23:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant