Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[CELEBORN-1640] NettyMemoryMetrics supports numHeapArenas, numDirectA…
…renas, tinyCacheSize, smallCacheSize, normalCacheSize, numThreadLocalCaches and chunkSize ### What changes were proposed in this pull request? `NettyMemoryMetrics` supports `numHeapArenas`, `numDirectArenas`, `tinyCacheSize`, `smallCacheSize`, `normalCacheSize`, `numThreadLocalCaches` and `chunkSize` from `PooledByteBufAllocatorMetric`. Meanwhile, remove `server_` prefix from metric name of netty memory metric in `monitoring.md`. ### Why are the changes needed? `PooledByteBufAllocatorMetric` provides the following API to support netty memory metrics: ``` public int numHeapArenas() { return this.allocator.numHeapArenas(); } public int numDirectArenas() { return this.allocator.numDirectArenas(); } public List<PoolArenaMetric> heapArenas() { return this.allocator.heapArenas(); } public List<PoolArenaMetric> directArenas() { return this.allocator.directArenas(); } public int numThreadLocalCaches() { return this.allocator.numThreadLocalCaches(); } public int tinyCacheSize() { return this.allocator.tinyCacheSize(); } public int smallCacheSize() { return this.allocator.smallCacheSize(); } public int normalCacheSize() { return this.allocator.normalCacheSize(); } public int chunkSize() { return this.allocator.chunkSize(); } public long usedHeapMemory() { return this.allocator.usedHeapMemory(); } public long usedDirectMemory() { return this.allocator.usedDirectMemory(); } ``` `NettyMemoryMetrics` only supports `usedHeapMemory` and `usedDirectMemory`, which could support `numHeapArenas`, `numDirectArenas`, `tinyCacheSize`, `smallCacheSize`, `normalCacheSize`, `numThreadLocalCaches` and `chunkSize` from `PooledByteBufAllocatorMetric`. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? [Celeborn Grafana Dashboard](https://stenicholas.grafana.net/public-dashboards/a520ca36a33843a38bbde28387023f97) Closes apache#2802 from SteNicholas/CELEBORN-1640. Authored-by: SteNicholas <[email protected]> Signed-off-by: mingji <[email protected]>
- Loading branch information