aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/monlib/dynamic_counters/encode.h
blob: 1a3b253518998bc84003735a062d53a36665639c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#pragma once

#include "counters.h"

#include <library/cpp/monlib/encode/encoder.h> 
#include <library/cpp/monlib/encode/format.h>

namespace NMonitoring {

    THolder<ICountableConsumer> CreateEncoder(
        IOutputStream* out,
        EFormat format,
        TCountableBase::EVisibility visibility = TCountableBase::EVisibility::Public
    );

    THolder<ICountableConsumer> AsCountableConsumer( 
        NMonitoring::IMetricEncoderPtr encoder, 
        TCountableBase::EVisibility visibility = TCountableBase::EVisibility::Public); 
 
    void ToJson(const TDynamicCounters& counters, IOutputStream* out);

    TString ToJson(const TDynamicCounters& counters);
}