ExMCP.Server.CancellationTracker.Default (ex_mcp v1.0.0-rc.8)

Copy Markdown View Source

Default cancellation tracker.

Supports the two conventions ExMCP handlers use to observe cancellation:

  • a :cancelled_requests MapSet in the handler state, which is updated in place, and
  • an :active_requests map of request_id => pid, whose worker process is sent {:cancelled, request_id} so long-running work can stop early.

Handler states that use neither are returned untouched.