writeproxy

package
v1.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 19, 2024 License: AGPL-3.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TaggedMetricName   = "graphite_tagged"
	UntaggedMetricName = "graphite_untagged"
)

Variables

This section is empty.

Functions

func LabelsFromTaggedName

func LabelsFromTaggedName(name string, tags []string, builder *labels.Builder) (labels.Labels, error)

func LabelsFromUntaggedName

func LabelsFromUntaggedName(name string, builder *labels.Builder) labels.Labels

Types

type Config

type Config struct {
	RemoteWriteConfig remotewrite.Config `yaml:"remote_write"`
}

func (*Config) RegisterFlags

func (c *Config) RegisterFlags(flags *flag.FlagSet)

RegisterFlags adds the flags required to config this to the given FlagSet

func (*Config) RegisterFlagsWithPrefix

func (c *Config) RegisterFlagsWithPrefix(prefix string, f *flag.FlagSet)

type MetricDataPayload

type MetricDataPayload []*schema.MetricData

func (MetricDataPayload) GeneratePreallocTimeseries

func (m MetricDataPayload) GeneratePreallocTimeseries(ctx context.Context) ([]mimirpb.PreallocTimeseries, error)

func (MetricDataPayload) GeneratePromMetrics

func (m MetricDataPayload) GeneratePromMetrics() ([]labels.Labels,
	[]mimirpb.Sample,
	error)

func (MetricDataPayload) GeneratePromTimeSeries

func (m MetricDataPayload) GeneratePromTimeSeries(ctx context.Context) ([]prompb.TimeSeries, error)

type Recorder

type Recorder interface {
	// contains filtered or unexported methods
}

func NewRecorder

func NewRecorder(reg prometheus.Registerer) Recorder

NewRecorder returns a new Prometheus metrics Recorder. It ensures that the graphite ingester metrics are properly registered.

type RemoteWriteProxy

type RemoteWriteProxy struct {
	// contains filtered or unexported fields
}

func NewRemoteWriteProxy

func NewRemoteWriteProxy(client remotewrite.Client, recorder Recorder) *RemoteWriteProxy

func (*RemoteWriteProxy) ServeHTTP

func (wp *RemoteWriteProxy) ServeHTTP(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL