Documentation
¶
Overview ¶
Package prometheusreceiver autodiscovers and scrapes Prometheus metrics handlers, often served at /metrics.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFactory ¶
func NewFactory() component.ReceiverFactory
NewFactory creates a new Prometheus receiver factory.
Types ¶
type Config ¶
type Config struct { config.ReceiverSettings `mapstructure:",squash"` // squash ensures fields are correctly decoded in embedded struct PrometheusConfig *promconfig.Config `mapstructure:"-"` BufferPeriod time.Duration `mapstructure:"buffer_period"` BufferCount int `mapstructure:"buffer_count"` // UseStartTimeMetric enables retrieving the start time of all counter metrics // from the process_start_time_seconds metric. This is only correct if all counters on that endpoint // started after the process start time, and the process is the only actor exporting the metric after // the process started. It should not be used in "exporters" which export counters that may have // started before the process itself. Use only if you know what you are doing, as this may result // in incorrect rate calculations. UseStartTimeMetric bool `mapstructure:"use_start_time_metric"` StartTimeMetricRegex string `mapstructure:"start_time_metric_regex"` // ConfigPlaceholder is just an entry to make the configuration pass a check // that requires that all keys present in the config actually exist on the // structure, ie.: it will error if an unknown key is present. ConfigPlaceholder interface{} `mapstructure:"config"` }
Config defines configuration for Prometheus receiver.
Click to show internal directories.
Click to hide internal directories.