diff options
author | Vlad Kuznetsov <va-kuznecov@ydb.tech> | 2025-04-24 19:18:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-04-24 17:18:05 +0000 |
commit | 7e8c6446058eefa9aa124cb7c2042fad9590b695 (patch) | |
tree | 1324f1de957e53d3f5162cd6cf9121349fb5adc5 | |
parent | e7c01edc736d395b9a1b19d32d623fd9799f1853 (diff) | |
download | ydb-7e8c6446058eefa9aa124cb7c2042fad9590b695.tar.gz |
Fix histogram counters calculation error due to implicit round down (#16072)
-rw-r--r-- | ydb/core/blobstorage/vdisk/common/vdisk_histogram_latency.cpp | 3 | ||||
-rw-r--r-- | ydb/core/grpc_services/counters/counters.cpp | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/ydb/core/blobstorage/vdisk/common/vdisk_histogram_latency.cpp b/ydb/core/blobstorage/vdisk/common/vdisk_histogram_latency.cpp index 8d80758520c..8a71b64895c 100644 --- a/ydb/core/blobstorage/vdisk/common/vdisk_histogram_latency.cpp +++ b/ydb/core/blobstorage/vdisk/common/vdisk_histogram_latency.cpp @@ -24,7 +24,7 @@ namespace NKikimr { void TLtcHisto::Collect(TDuration d, ui64 size) { if (Histo) { - Histo->Collect(d.MilliSeconds()); + Histo->Collect(d.MillisecondsFloat()); } if (size) { ThroughputBytes->Add(size); @@ -33,4 +33,3 @@ namespace NKikimr { } // NKikimr } // NKikimr - diff --git a/ydb/core/grpc_services/counters/counters.cpp b/ydb/core/grpc_services/counters/counters.cpp index 5036c759975..89ec26b932e 100644 --- a/ydb/core/grpc_services/counters/counters.cpp +++ b/ydb/core/grpc_services/counters/counters.cpp @@ -232,7 +232,7 @@ public: *GetResponseCounterByStatus(status) += 1; } - Histo->Collect(requestDuration.MilliSeconds()); + Histo->Collect(requestDuration.MillisecondsFloat()); } NYdbGrpc::ICounterBlockPtr Clone() override { |