/
githubmirror
/
nbs
Обзор
Документация
Войти
/
githubmirror
/
nbs
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
cloud/blockstore/libs/diagnostics/stats_helpers.cpp
39 строк
1 KB
Andrei Galibin
[NBS] add "type" field to the StartEndpoint metric (#4807)
15 дек 2025, 15:29
Не верифицирован
15 дек 2025, 15:29
cc4dd10
Код
Авторство
О чём код?
#include "stats_helpers.h" #include <cloud/blockstore/libs/service/request.h> #include <cloud/blockstore/libs/service/request_helpers.h> namespace NCloud::NBlockStore { //////////////////////////////////////////////////////////////////////////////// TRequestCounters MakeRequestCounters( ITimerPtr timer, TRequestCounters::EOptions options, EHistogramCounterOptions histogramCounterOptions, const TVector<TSizeInterval>& executionTimeSizeClasses) { return TRequestCounters( std::move(timer), BlockStoreRequestsCount, [] (TRequestCounters::TRequestType t) { Y_DEBUG_ABORT_UNLESS(t < BlockStoreRequestsCount); const auto bt = static_cast<EBlockStoreRequest>(t); return GetBlockStoreRequestName(bt); }, [] (TRequestCounters::TRequestType t) { Y_DEBUG_ABORT_UNLESS(t < BlockStoreRequestsCount); const auto bt = static_cast<EBlockStoreRequest>(t); return IsNonLocalReadWriteRequest(bt); }, [] (TRequestCounters::TRequestType t) { Y_DEBUG_ABORT_UNLESS(t < BlockStoreRequestsCount); const auto bt = static_cast<EBlockStoreRequest>(t); return bt == EBlockStoreRequest::StartEndpoint; }, options, histogramCounterOptions, executionTimeSizeClasses); } } // namespace NCloud::NBlockStore