Skip to content
Snippets Groups Projects

Saving counters result as monitoring histogram

Merged Valerii Kholoimov requested to merge dev_kholoimov_monitoring_counters_histogram into master
2 files
+ 16
7
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -78,18 +78,25 @@ namespace Allen::Monitoring {
m_bins.push_back(0);
}
void updateBin(int bin_index, double value)
void addAvCounter(const std::string& label)
{
m_bins[bin_index + 1] = static_cast<int>(value);
m_totNEntries = value;
m_labels.insert(m_labels.end(), {label + "_sum", label + "_n_enties"});
m_maxValue += 2;
m_bins.insert(m_bins.end(), 2, 0);
}
void updateBin(int bin_index, unsigned value)
{
m_bins[bin_index + 1] = value;
m_totNEntries += value;
}
std::string m_title;
std::vector<int> m_bins;
std::vector<unsigned> m_bins;
int m_minValue = 0;
int m_maxValue = 0;
std::vector<std::string> m_labels;
double m_totNEntries = 0.0;
unsigned m_totNEntries = 0.0;
};
struct AccumulatorManager {
Loading