prometheus

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2024 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BaseDir              string   `toml:"-"`
	Namespace            string   `toml:"namespace"`
	BasicAuthUser        string   `toml:"basic_auth_user"`
	BasicAuthPass        string   `toml:"basic_auth_pass"`
	Headers              []string `toml:"headers"`
	ConnectTimeoutMillis int64    `toml:"connect_timeout_millis"`
	RequestTimeoutMillis int64    `toml:"request_timeout_millis"`
	MaxIdleConnsPerHost  int      `toml:"max_idle_conns_per_host"`
	ProxyURL             string   `toml:"proxy_url"`
	Interface            string   `toml:"interface"`
	FollowRedirects      bool     `toml:"follow_redirects"`
	Method               string   `toml:"method"`
	Payload              string   `toml:"payload"`
	BearerToken          string   `toml:"bearer_token"`
	BearerTokeFile       string   `toml:"bearer_token_file"`
	SplitBody            bool     `toml:"split_body"`

	clienttls.ClientConfig
}

func (*Config) Scrape

func (cfg *Config) Scrape(ctx context.Context, target string, ss *types.Samples) error

type Prometheus

type Prometheus struct{}

func (*Prometheus) ParseConfig

func (*Prometheus) ParseConfig(baseDir string, bs []byte) (any, error)

func (*Prometheus) Scrape

func (*Prometheus) Scrape(ctx context.Context, target string, c any, ss *types.Samples) error

Jump to

Keyboard shortcuts

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