Vercel Sandbox now supports memory observability

脚本小子小柯 专家 1小时前 284 浏览 9 点赞 约 1 分钟

Vercel Sandbox observability now includes memory usage data.

You can access sandbox memory usage data in the dashboard and through the CLI via the vercel metrics command.

Sandbox observability memory in the dashboard
The Memory Usage card reports average, P75, and P95 memory across your sandboxes, alongside the existing CPU usage and data transfer metrics on the sandbox overview page and the project and team-level pages.

On the sandbox detail page, charts are designed to show how close a sandbox is running to its memory ceiling by:

  • Automatically scaling the y-axis to sandbox's memory limit
  • Adding a dashed reference line at 85% of that limit
Sandbox memory is also available in the Observability query builder as the memoryUsedBytes measure on the sandbox usage event. You can build custom queries against it and create alerts from the chart.

Sandbox memory observability in the CLI
Sandbox observability data is also available through the Vercel CLI via the vercel metrics command under vercel.sandbox.memory_used_bytes. Run the command in a linked project for project-specific data, or append --all to see aggregate data across all projects in your team.

The CLI returns:

  • The metric
  • The reporting period
  • The measurement interval
  • The project the sandbox is associated with
  • A graph of memory usage, with min, max and avg values
Learn more in the Sandbox documentation.

读完这篇,你就知道 Vercel 的沙箱环境现在能实时监控内存使用情况了。仪表盘里有 Memory Usage 卡片,能看到平均值、P75、P95 三组数据,和 CPU、带宽一起排列。最有意思的是沙箱详情页的图表,会自动把 Y 轴拉满到内存上限,再加一条虚线标记在 85% 位置,一目了然地看出离上限还有多远。

后台查询 builder 里新增了 memoryUsedBytes 这个指标,能自定义查询和报警。CLI 端直接用 vercel metrics 拉数据,带 --all 能看到团队全局情况,返回的图表里有最小、最大、平均值,还附带了报告周期和测量间隔,甚至能关联到具体的 project。如果你正在处理内存泄漏或者想优化沙箱的资源使用,这套监控组合应该很实用。

求助

全部回复 (1)

想当场把话说完?进全球 AI 聊天室,登录就能开口。

副
副业中创业者 初级 56分钟前

看那 P95 的指标也就图个心理安慰,真要靠 vercel metrics 去排查内存泄漏,这运维成本够呛。

0 回复

发表回复

支持 Markdown 格式