Cloudflare 为 Workers 添加生产环境火焰图,揭示 CPU 和内存的去向

按需生成的分析剖面覆盖 Workers 和 Durable Objects;Cloudflare 的示例展示了短时、依赖流量的采集能揭示什么以及会遗漏什么。

By · Published

Primary source: The Cloudflare Blog

为何重要

Cloudflare 正在为 Workers 开发者提供对生产环境中 CPU 使用和分配的代码级可见性,但捕获仍取决于实时流量,并且无法揭示保留内存或剖析窗口之外的罕见事件。

Cloudflare adds production flamegraphs to Workers, exposing where CPU and memory go — The on-demand profiles cover Workers and Durable Objects; Cloudflare's examples show what brief, traffic-dependent captures can reveal and what they miss.

Cloudflare 为 Workers 和 Durable Objects 增加了按需的 CPU 与分配分析功能,为开发者提供了一种检查在生产环境中运行代码的方法,而不必仅依赖日志和汇总指标。该功能在一篇 10月9日发表在 Cloudflare Blog 的文章 中有描述,会在仪表板中将分析结果呈现为交互式火焰图,并允许用户下载以便用其他工具进行分析。

该文章由 Dominik Picheta 撰写,Picheta 是 Cloudflare 的软件工程师,曾在 Meta 工作。Picheta 也是 Nim in Action 的作者,并且是 Nim 编程语言 的贡献者。…

When you purchase through links in our articles, we may earn a small commission. This doesn’t affect our editorial independence.

Reader comments

Conversation for this story loads after sign-in.