prometheus: Fix internode stats (#17594)

Internode calculation was done inside S3 handlers, fix it by moving it
to internode handlers.

Remove admin stats since it is not used.
This commit is contained in:
Anis Eleuch
2023-07-08 15:35:11 +01:00
committed by GitHub
parent 7af78af1f0
commit 6d0bc5ab1e
10 changed files with 164 additions and 172 deletions

View File

@@ -2018,20 +2018,20 @@ func getNetworkMetrics() *MetricsGroup {
})
metrics = append(metrics, Metric{
Description: getInterNodeSentBytesMD(),
Value: float64(connStats.TotalOutputBytes),
Value: float64(connStats.internodeOutputBytes),
})
metrics = append(metrics, Metric{
Description: getInterNodeReceivedBytesMD(),
Value: float64(connStats.TotalInputBytes),
Value: float64(connStats.internodeInputBytes),
})
}
metrics = append(metrics, Metric{
Description: getS3SentBytesMD(),
Value: float64(connStats.S3OutputBytes),
Value: float64(connStats.s3OutputBytes),
})
metrics = append(metrics, Metric{
Description: getS3ReceivedBytesMD(),
Value: float64(connStats.S3InputBytes),
Value: float64(connStats.s3InputBytes),
})
return
})