oprobe OpenDAL operator 性能剖析器

找出 OpenDAL 的修复,再证明它有效

oprobe 按阶段记录 OpenDAL operator 发出的每个请求,为每条发现指出一个改动,并在上线之前用 A/B 测试证明它。

未经公证:首次打开方法
  • macOS 15 及以上:第一次打开时,到“系统设置 → 隐私与安全性”点“仍要打开”。
  • Windows:如果 SmartScreen 拦下,点“更多信息”,再点“仍要运行”。
入门指南里的实际输出 Attention
$ oprobe demo
下一步
  • oprobe prove 20261130-102347-bb72 tail_stragglers
它给出的补救措施 remedy: layers.tail_cut + layers.retry.min_delay — re-issue requests far slower than their peers, after a short retry backoff (TailCutLayer + RetryLayer::with_min_delay)
lab://demo · small-files · 8.0 s1001.7 ops/s · p50 9.71ms · p99 261ms

从一次运行到已证明的改动

开始使用

安装脚本会装上应用和命令行。GitHub Releases 页面还有 Windows 的 .msi 和 PowerShell 脚本、.deb 和 .rpm 软件包,以及给服务器和 CI 用的纯命令行版。

  1. 安装(macOS、Linux)

    curl -fsSL https://github.com/hxddh/oprobe/releases/latest/download/install.sh | sh
  2. 在本机剖析一个“行为不良”的 S3 实验室,无需任何账号

    oprobe demo
    查看实际输出
    [Attention] 2.6% of GetObject, 2.4% of PutObject and 2.3% of HeadObject requests wait far longer for
      the server's first byte than their peers (stragglers).
      lab://demo · small-files · 8.0 s · run 20261130-102347-bb72
      ▲ 1 tail_stragglers (high confidence)
          123 GetObject stragglers wait ~261ms for the first byte against ~9.57ms for a typical
          GetObject; 59 PutObject stragglers wait ~261ms for the first byte against ~9.52ms for a
          typical PutObject; 18 HeadObject stragglers wait ~260ms for the first byte against ~9.52ms for
          a typical HeadObject; operation p50 9.71ms · p99 261ms
          remedy: layers.tail_cut + layers.retry.min_delay — re-issue requests far slower than their
            peers, after a short retry backoff (TailCutLayer + RetryLayer::with_min_delay)
          note: each cut request is sent again: more requests per operation, and more bytes when the cut
            one had started its body
          next: oprobe prove 20261130-102347-bb72 tail_stragglers
      1001.7 ops/s · 56.4 MiB/s · p50 9.71ms · p99 261ms · errors 0.00%
      full profile: oprobe show 20261130-102347-bb72 --detail · terms: https://github.com/hxddh/oprobe/blob/v9.10.0/docs/concepts.md#glossary
  3. 对首要发现的补救措施做 A/B 测试

    oprobe prove last

常见问题

支持哪些存储服务?

常见的都已内置:S3、GCS、Azure Blob、OSS、COS、OBS、B2 和 WebDAV,还有本地文件系统、内存和实验室。从源码构建时加 --features all-services 就包含其余的服务。

可以直接对真实存储运行吗?

一次运行只写在新的 oprobe-run-<id>/ 前缀下,结束时删除;被强行终止的运行可能留下它。

  • --dry-run 只打印计划,不发出任何请求。
  • --read-only 拒绝一切写入。
  • --max-requests、--max-bytes 和 --max-duration 是硬性预算。
能把它当作 CI 关卡吗?

要谨慎:oprobe 是性能剖析器,不是 CI 关卡,共享存储上的剖析结果每次运行都会有出入。

  • -o json 输出一份 JSON 文档,退出码是稳定的。
  • 改动让 operator 变差时,oprobe prove 以退出码 3 结束。