userver: utils::statistics::MetricsStorage Class Reference
⚠️ This is the documentation for an old userver version. Click here to switch to the latest version.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages Concepts
utils::statistics::MetricsStorage Class Referencefinal

Storage of metrics registered with MetricTag<Metric> More...

#include <userver/utils/statistics/metrics_storage.hpp>

Public Member Functions

std::vector< EntryRegisterIn (Storage &statistics_storage)
 
template<typename Metric >
Metric & GetMetric (const MetricTag< Metric > &tag)
 Get metric data by type.
 
void ResetMetrics ()
 

Detailed Description

Storage of metrics registered with MetricTag<Metric>

Note
The class is thread-safe. See also the note about thread-safety on MetricTag<Metric>.

Definition at line 15 of file metrics_storage.hpp.

Member Function Documentation

◆ GetMetric()

template<typename Metric >
Metric & utils::statistics::MetricsStorage::GetMetric ( const MetricTag< Metric > &  tag)
inline

Get metric data by type.

Definition at line 23 of file metrics_storage.hpp.


The documentation for this class was generated from the following file: