A held connection is not a long tool call
Tick’s MCP surface and the agent paths around BuilderHelp and RuleCaddie all hit the same shape of work: a tool call that can take longer than a polite HTTP timeout. The 2026-07-28 MCP revision made remote servers protocol-stateless and graduated Tasks into a real extension. The trap we still see is treating “long-running” as “hold this connection until the worker is done.” A held connection is a transport choice. A long tool call is a job with an id, a status, and a store that survives the socket.
Blocking the request hides the job
When tools/call waits on the wire for OCR, a packet rebuild, or a bulk checklist sync, every proxy and load balancer in the path becomes part of the tool’s runtime. The client sees one long request. The server sees a worker tied to a socket. Drop the connection and you lose both the progress signal and any clear place to resume.
That pattern worked for demos on a single process. It fails the moment you put Streamable HTTP behind round-robin — the same move the July 2026 MCP core now expects. Stateless transport means any instance can take the next call. It does not mean the work finished when the response headers went out.
We already refuse to treat a truncated model stream as a finished answer. The same discipline applies one layer down: an open tool request that dies mid-work is not a completed CallToolResult, and it is not a clean cancel either.
Tasks make the job addressable
The Tasks extension (io.modelcontextprotocol/tasks) lets the server answer tools/call with a CreateTaskResult — resultType task, a taskId, a status, and polling hints — instead of the final tool payload. The client drives tasks/get, tasks/update when input is required, and tasks/cancel. The socket that created the task does not have to stay open for the duration.
That is the contract for work that outlives a few seconds. File processing, batch transforms, and anything that waits on a human mid-flight belong here. Returning the handle only after the task is findable in a durable store is part of the extension’s own shape: a taskId that vanishes when the pod restarts is a sticky session wearing a new name.
This is different from caching tools/list with ttlMs. Catalog freshness is about what the agent is allowed to call. Task durability is about where in-flight work lives after the call that started it returns.
Local memory is not the task store
Removing Mcp-Session-Id and sticky sessions is the easy half of the migration. The hard half is moving progress, partial results, and cancellation out of process memory. If tasks/get only works on the instance that accepted tools/call, you still have a session — you just renamed the failure mode.
Put task records in shared durable storage before you return the handle. Workers update status there; any instance can answer a poll. Make the create path idempotent so a client retry after a dropped connection does not spawn a second job for the same intent.
When the tool needs mid-flight input, surface input_required on the task and take answers through tasks/update. Do not reopen a private SSE channel to the original pod and pretend that is protocol. The state has to travel in the payload so the next hop can continue the work.
What we check before shipping a long tool
For every MCP tool that can exceed a normal request budget, confirm the client declares Tasks support and the server returns a task handle with a findable taskId — not a stretched tools/call. Confirm tasks/get works after killing the creating connection and after routing the poll to a different instance.
Confirm cancel actually stops the worker, not just the UI spinner. Confirm a retry with the same client intent does not double-run side effects. Confirm the product UI treats the task as its own lifecycle — pending, working, input required, done, failed — the same way we already treat tool cards instead of dumping JSON into a chat bubble.
The milestone is a long tool the load balancer cannot accidentally finish. Until the job has an id outside the socket, you are still holding a connection and calling it architecture.
Questions
- When should tools/call return a task instead of a result?
- When the work can outlive a polite HTTP timeout, needs mid-flight input, or must survive a dropped client connection. Short lookups still return immediately.
- Is this the same as reconnecting a chat stream?
- No. Reconnect reattaches to an in-flight generation. A task handle is a durable job id for tool work that should not depend on the original socket at all.
- Can we keep sticky sessions for long tools?
- You can, but you are fighting the 2026-07-28 core. Prefer a shared task store and ordinary round-robin. Sticky affinity is a temporary patch, not the contract.
Sources
- SEP-2663: Tasks Extension — tools/call may return a task handle; clients poll tasks/get / update / cancel.
- MCP Tasks Extension overview — Durable task store before CreateTaskResult; worker separate from the creating connection.
- MCP is going stateless — New Relic — 2026-07-28 core drops sessions; Tasks for work that should not hold a socket open.
- Related: A tools/list cache is not a session
- Related: A tool call is not a chat bubble