featzhang commented on PR #27774: URL: https://github.com/apache/flink/pull/27774#issuecomment-4365407494
Self-review pass (amended into the second commit, HEAD `d2449326c60`): **API polish** - Removed the dead backwards-compatible 3-arg `TopNMetricsResponseBody` constructor; every call-site was already on the 5-arg form. - All five top-level list fields are now null-guarded consistently (previously only the two new fields were). - `CpuConsumerInfo.subtaskId` is now `Integer` and reported as `null` for TaskManager-scoped CPU readings, matching the `null`-means-unavailable convention used by `SourceLagInfo`. Sentinel `-1` is gone. - `SourceLagInfo` javadoc and the TS interface are aligned on `null` (previously claimed `-1`). - `TopNMetricsHeaders.getDescription()` now enumerates the five actual dimensions instead of the stale 3-dimension wording that was leaking into the OpenAPI doc. **Handler simplification** - `findOperatorMetric`: dropped the never-taken bare-key fallback; only the operator-scoped `".<metricName>"` suffix is matched now, with an updated comment tying the behaviour to FLIP-33. - Removed the `getFriendlyTaskManagerName` helper that read `taskmanager.id` / `taskmanager.host` — no such metrics are exported anywhere in the tree, so the helper always fell through to `tmId`. - Source-lag aggregation uses `Double maxFetchLag / maxEmitLag = null` instead of `Double.NEGATIVE_INFINITY` sentinels. - Repeated `?topN=…` query parameters now follow the "last value wins" HTTP convention. **REST snapshot** - `rest_api_v1.snapshot` regenerated to actually include `topBusyOperators` and `topLaggingSources` (the snapshot had been missed when those fields were first added). Verified locally: `spotless:check`, `checkstyle:check`, `TopNMetrics*` tests (20/20 green), and `RuntimeRestAPIStabilityTest` pass. No behavioural change for callers that already consumed the 5-dimension response. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
