Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LabelsToResource ¶
func LabelsToResource(labels labels.Labels) *resource_pb.Resource
func ReadProgressFile ¶
ReadProgressFile reads the progress file in the given directory and returns the saved offset.
func SaveProgressFile ¶
SaveProgressFile saves a progress file with the given offset in directory.
Types ¶
type Appender ¶
type Appender interface {
Append(s SizedMetric)
}
Appender appends a time series with exactly one data point.
type MetadataGetter ¶
type PrometheusReader ¶
type PrometheusReader struct {
// contains filtered or unexported fields
}
func NewPrometheusReader ¶
func NewPrometheusReader( logger log.Logger, walDirectory string, tailer tail.WalTailer, filters [][]*labels.Matcher, metricRenames map[string]string, metadataGetter MetadataGetter, appender Appender, metricsPrefix string, maxPointAge time.Duration, scrapeConfig []*promconfig.ScrapeConfig, failingReporter common.FailingReporter, ) *PrometheusReader
NewPrometheusReader is the PrometheusReader constructor
func (*PrometheusReader) CurrentSegment ¶
func (r *PrometheusReader) CurrentSegment() int
func (*PrometheusReader) Next ¶
func (r *PrometheusReader) Next()
type SizedMetric ¶ added in v0.24.0
type SizedMetric struct {
// contains filtered or unexported fields
}
SizedMetric encapsulates a small number of points w/ precomputed approximate size.
func NewSizedMetric ¶ added in v0.24.0
func NewSizedMetric(metric *metric_pb.Metric, count, size int) SizedMetric
func (SizedMetric) Count ¶ added in v0.24.0
func (s SizedMetric) Count() int
func (SizedMetric) Metric ¶ added in v0.24.0
func (s SizedMetric) Metric() *metric_pb.Metric
func (SizedMetric) Size ¶ added in v0.24.0
func (s SizedMetric) Size() int
Click to show internal directories.
Click to hide internal directories.