跳转到主要内容
监控与采集相关接口/性能剖析
POSTProfiling起始版本 1.0同步需要认证

检查回归

检查性能回归之间基线比较剖析。

调试可用性

在线调试

使用当前认证信息和示例参数提交 Mock 请求。

请求参数

请求体字段

  • baselineIdString必填

    基线ID。

    示例: bl-20240101

  • compareIdString必填

    对比ID。

    示例: sess-cmp002

  • thresholdsObject必填

    阈值列表。

    • functionDeltaPctLong

      函数变化量比例。

      示例: 5

    • newHotspotMinPctLong

      新热点最小比例。

      示例: 2

    • criticalDeltaPctLong

      变化量百分比触发严重级别回归。

      示例: 20

    • criticalHotspotPctLong

      热点百分比触发严重级别分类。

      示例: 10

响应状态

200 OK

该 API 成功时返回以下响应结构。

  • reportIdString

    唯一标识符回归报表。

    示例: rpt-xyz789

  • baselineLabelString

    基线标签。

    示例: v1.2.0-release

  • compareLabelString

    比较标签。

    示例: v1.3.0-candidate

  • profileTypeString

    已使用回归分析。

    示例: cpu

  • regressionDetectedBoolean

    性能回归已检测。

    示例: true

  • severityString

    告警级别。

    示例: WARNING

  • changedFunctionsList

    变更函数。

    示例: (nested array)

    • funcNameString

      完全限定名称函数变更。

      示例: net/http.(*Transport).roundTrip

    • baselinePctLong

      基线百分比。

      示例: 3.2

    • comparePctLong

      比较百分比。

      示例: 8.7

    • deltaPctLong

      变化量百分比。

      示例: 5.5

    • directionString

      方向。

      示例: increased

  • newHotspotsList

    新增热点。

    示例: (nested array)

    • funcNameString

      完全限定名称函数变更。

      示例: net/http.(*Transport).roundTrip

    • baselinePctLong

      基线百分比。

      示例: 3.2

    • comparePctLong

      比较百分比。

      示例: 8.7

    • deltaPctLong

      变化量百分比。

      示例: 5.5

    • directionString

      方向。

      示例: increased

  • disappearedHotspotsList

    消失的热点。

    示例: (nested array)

    • funcNameString

      完全限定名称函数变更。

      示例: net/http.(*Transport).roundTrip

    • baselinePctLong

      基线百分比。

      示例: 3.2

    • comparePctLong

      比较百分比。

      示例: 8.7

    • deltaPctLong

      变化量百分比。

      示例: 5.5

    • directionString

      方向。

      示例: increased

  • createdAtString

    创建时间。

    示例: 2026-01-15T08:00:00Z

请求地址

POST/api/v1/profiling/regression/check

/api/v1/profiling/regression/check

操作 ID

CheckRegression

永久链接

请求示例

curl -X POST '{host}/api/v1/profiling/regression/check' -H 'Authorization: Bearer {token}' -H 'Content-Type: application/json' -d '{"baselineId":"bl-20240101","compareId":"sess-cmp002","thresholds":{"functionDeltaPct":5.0,"newHotspotMinPct":2.0,"criticalDeltaPct":20.0,"criticalHotspotPct":10.0}}'

响应示例

200
{
  "reportId": "rpt-xyz789",
  "baselineLabel": "v1.2.0-release",
  "compareLabel": "v1.3.0-candidate",
  "profileType": "cpu",
  "regressionDetected": true,
  "severity": "WARNING",
  "changedFunctions": [
    {}
  ],
  "newHotspots": [
    {}
  ]
}

变更历史

此 API 暂无变更历史记录。

查看全部变更历史