Cloudflare rebuilt the Workflows control plane for the agentic era!
Hey everyone, it's Shiichan! Today's story is about infrastructure — specifically, swapping out the whole foundation of a live service without ever turning it off. I love this kind of behind-the-scenes stuff!
Cloudflare Blog
What was announced?
On the Cloudflare Blog, the team announced that they rebuilt the control plane (the "command center") of Workflows for the agentic era.
With this, the limit on concurrent instances jumps from 4,500 to 50,000, the creation rate goes from 100 to 300 instances per second per account, and the number of instances you can queue for a single Workflow doubles from 1 million to 2 million!
The story so far
Workflows was originally designed around the idea that a human presses a button to kick things off. But lately, with AI agents running autonomously — think Project Think and the Agents SDK integration — Workflows are being created at machine speed.
fewer human-triggered workflows, and more agent-triggered workflows, created at machine speed.
Agents run in the background for hours or days and need durable execution: per-step retries, human-in-the-loop pauses, and recovery from failure. One agent session can spawn dozens of Workflows, and many agents together create thousands of instances in seconds.
In V1, though, a single per-account Durable Object called Account handled every create, update, and list operation — and that singleton became the bottleneck.
What changes
With the higher limits, workloads that fan out lots of agents at once are far less likely to jam up. And the new V2 limits are toggleable rather than hard caps, so raising them further in the future won't require another rearchitecture.
Listing instances also got faster and more stable thanks to consistent cursor pagination.
Dive Deep
V2 introduces two new characters (components) with clear roles.
First, SousChef (the "second in command" to Account). Each SousChef tracks the state and lifecycle of a subset of instances within a single Workflow, and there are many of them per account. Because they report back to Account efficiently, the former singleton no longer gets swamped — and as a bonus, you get per-workflow isolation.
Next, Gatekeeper. It hands out concurrency "slots" to each SousChef. When an instance is created, its SousChef leases a slot from Account; if it gets one, execution starts, and if not, the instance is queued. Gatekeeper runs on a 1-second cycle and batches all slot requests into a single JSRPC call so Account never overflows. It also uses max-min fairness — prioritizing awakened instances over brand-new ones — so every SousChef keeps making progress.
The key to reliability is the Durable Object alarm. Using its at-least-once execution and automatic retries, the team sets a "safety-net alarm" in the creation hot-path. Even if a background task fails due to eviction or a server failure, the alarm picks it up later so no instance gets stuck.
Here's what Workflow code looks like — you write step-by-step execution and event waits:
export class MyWorkflow extends WorkflowEntrypoint {
async run(event, step) {
const data = await step.do("fetch-data", async () => {
return fetchFromAPI();
});
const approval = await step.waitForEvent("approval", {
type: "approval",
timeout: "24 hours",
});
await step.do("process-and-save", async () => {
return store(transform(data));
});
}
}
The migration is impressive too. With millions of instances across thousands of customers still running, they taught the old Account DOs to behave as SousChefs and used a version flag to switch code paths. By reusing the existing SQL tables, they migrated with zero downtime — like changing a car's wheels while driving!
If you want to try it yourself, you can start from the Get Started guide or the build your first durable agent guide.
Wrap-up
- Cloudflare redesigned the Workflows control plane for the agentic era
- Limits rise to 50,000 concurrent, 300 creates per second, and 2 million queued
- The bottlenecked Account singleton is split horizontally via SousChef and Gatekeeper
- Durable Object alarms make creation safe while pushing heavy work off the hot-path
- The V1-to-V2 migration ran with zero downtime, like changing a car's wheels while driving
This one's for developers who want to run lots of agents in the background, and anyone learning to design large-scale distributed systems with Durable Objects!