Cloudflare

Profile production bottlenecks on demand with interactive flamegraphs

Production performance issues shouldn't require a detective badge.

3 min readInfoQ
Profile production bottlenecks on demand with interactive flamegraphs

Developers have long accepted that debugging in production means flying blind, until something breaks, and then you sift through logs, guess at the stack, and hope. Cloudflare's new on-demand CPU and memory profiling for Workers and Durable Objects changes that equation, and it matters because it brings the kind of observability that serverless architectures have historically made difficult. By allowing developers to trigger interactive flamegraphs directly on production workloads, Cloudflare is turning performance analysis from a postmortem art into a live, actionable practice.

The practical impact is immediate. When a function slows down under real traffic, you no longer need to reproduce the issue locally or add speculative instrumentation. You profile on demand, see exactly which code paths consume CPU or allocate memory, and fix the bottleneck while the system is running. This is especially valuable given the rise of concurrent request handling and response streaming, patterns that make traditional debugging harder. Cloudflare's approach aligns with the direction we saw when Stream Node.js apps on AWS Lambda with concurrent requests and response streaming was introduced; both platforms are acknowledging that developers need deeper visibility into how their functions behave under load, not just whether they pass integration tests.

What makes this more than a useful feature is how it reframes the relationship between developer and infrastructure. Profiling has historically been reserved for monoliths or dedicated virtual machines, because the overhead felt incompatible with multi-tenant, ephemeral compute. Cloudflare is betting that the trade-off is worth it, and we agree, provided the on-demand model keeps the cost and complexity low enough that teams actually use it. That same tension between power and accessibility surfaces in other operational tools we've covered. For example, the recent reliability upgrades in GitHub's Scale Your Self-Hosted Runners with ARC's Latest Reliability Upgrades show that observability is becoming a first-class concern across the CI/CD pipeline, not just runtime. The best tools are the ones that remove friction without adding overhead, and interactive flamegraphs on live Workers are a strong step in that direction.

The open question is whether this will shift how teams build for serverless. Flamegraphs are powerful, but they demand a certain fluency to interpret. Cloudflare has made them interactive, hovering, zooming, clicking, which lowers the bar compared to static SVG exports, but a developer still needs to understand what a wide red bar means and how to act on it. The real test will be whether the profiling data integrates naturally into existing workflows, or if it stays a power-user feature that only the most performance-sensitive teams adopt. If Cloudflare can make the output as intuitive as a request log, then production profiling becomes a default habit rather than a desperation move. That is the outcome we will be watching for.

From InfoQ

Cloudflare has introduced on-demand CPU and memory profiling for Workers and Durable Objects, allowing developers to investigate performance bottlenecks in production using interactive flamegraphs.

Read the original at InfoQ