Documentation
¶
Index ¶
- type EncodeProm
- func (e *EncodeProm) Cleanup(cleanupFunc interface{})
- func (e *EncodeProm) Encode(metricRecord config.GenericMap)
- func (e *EncodeProm) Gatherer() prometheus.Gatherer
- func (e *EncodeProm) GetChacheEntry(entryLabels map[string]string, m interface{}) interface{}
- func (e *EncodeProm) ProcessAggHist(m interface{}, labels map[string]string, values []float64) error
- func (e *EncodeProm) ProcessCounter(m interface{}, labels map[string]string, value float64) error
- func (e *EncodeProm) ProcessGauge(m interface{}, labels map[string]string, value float64, _ string) error
- func (e *EncodeProm) ProcessHist(m interface{}, labels map[string]string, value float64) error
- func (e *EncodeProm) Update(config config.StageParam)
- type Encoder
- func NewEncodeKafka(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
- func NewEncodeNone() (Encoder, error)
- func NewEncodeProm(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
- func NewEncodeS3(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
- type MetricsCommonInterface
- type MetricsCommonStruct
- func (m *MetricsCommonStruct) AddAggHist(name string, g interface{}, info *metrics.Preprocessed)
- func (m *MetricsCommonStruct) AddCounter(name string, g interface{}, info *metrics.Preprocessed)
- func (m *MetricsCommonStruct) AddGauge(name string, g interface{}, info *metrics.Preprocessed)
- func (m *MetricsCommonStruct) AddHist(name string, g interface{}, info *metrics.Preprocessed)
- func (m *MetricsCommonStruct) MetricCommonEncode(mci MetricsCommonInterface, metricRecord config.GenericMap)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EncodeProm ¶
type EncodeProm struct {
// contains filtered or unexported fields
}
nolint:revive
func (*EncodeProm) Cleanup ¶
func (e *EncodeProm) Cleanup(cleanupFunc interface{})
callback function from lru cleanup
func (*EncodeProm) Encode ¶
func (e *EncodeProm) Encode(metricRecord config.GenericMap)
Encode encodes a metric before being stored; the heavy work is done by the MetricCommonEncode
func (*EncodeProm) Gatherer ¶
func (e *EncodeProm) Gatherer() prometheus.Gatherer
func (*EncodeProm) GetChacheEntry ¶
func (e *EncodeProm) GetChacheEntry(entryLabels map[string]string, m interface{}) interface{}
func (*EncodeProm) ProcessAggHist ¶
func (e *EncodeProm) ProcessAggHist(m interface{}, labels map[string]string, values []float64) error
func (*EncodeProm) ProcessCounter ¶
func (e *EncodeProm) ProcessCounter(m interface{}, labels map[string]string, value float64) error
func (*EncodeProm) ProcessGauge ¶
func (*EncodeProm) ProcessHist ¶
func (e *EncodeProm) ProcessHist(m interface{}, labels map[string]string, value float64) error
func (*EncodeProm) Update ¶
func (e *EncodeProm) Update(config config.StageParam)
type Encoder ¶
type Encoder interface { Encode(in config.GenericMap) Update(config.StageParam) }
func NewEncodeKafka ¶
func NewEncodeKafka(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
NewEncodeKafka create a new writer to kafka
func NewEncodeProm ¶
func NewEncodeProm(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
func NewEncodeS3 ¶ added in v0.1.5
func NewEncodeS3(opMetrics *operational.Metrics, params config.StageParam) (Encoder, error)
NewEncodeS3 creates a new writer to S3
type MetricsCommonInterface ¶
type MetricsCommonInterface interface { GetChacheEntry(entryLabels map[string]string, m interface{}) interface{} ProcessCounter(m interface{}, labels map[string]string, value float64) error ProcessGauge(m interface{}, labels map[string]string, value float64, key string) error ProcessHist(m interface{}, labels map[string]string, value float64) error ProcessAggHist(m interface{}, labels map[string]string, value []float64) error }
type MetricsCommonStruct ¶
type MetricsCommonStruct struct {
// contains filtered or unexported fields
}
func NewMetricsCommonStruct ¶
func NewMetricsCommonStruct(opMetrics *operational.Metrics, maxCacheEntries int, name string, expiryTime api.Duration, callback putils.CacheCallback) *MetricsCommonStruct
func (*MetricsCommonStruct) AddAggHist ¶
func (m *MetricsCommonStruct) AddAggHist(name string, g interface{}, info *metrics.Preprocessed)
func (*MetricsCommonStruct) AddCounter ¶
func (m *MetricsCommonStruct) AddCounter(name string, g interface{}, info *metrics.Preprocessed)
func (*MetricsCommonStruct) AddGauge ¶
func (m *MetricsCommonStruct) AddGauge(name string, g interface{}, info *metrics.Preprocessed)
func (*MetricsCommonStruct) AddHist ¶
func (m *MetricsCommonStruct) AddHist(name string, g interface{}, info *metrics.Preprocessed)
func (*MetricsCommonStruct) MetricCommonEncode ¶
func (m *MetricsCommonStruct) MetricCommonEncode(mci MetricsCommonInterface, metricRecord config.GenericMap)
Source Files
¶
Click to show internal directories.
Click to hide internal directories.