prom

package
v5.15.1 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Clusters = ClustersType{
	// contains filtered or unexported fields
}

Functions

func Init

func Init() error

Types

type ClusterType

type ClusterType struct {
	Opts       config.ClusterOptions
	Transport  *http.Transport
	PromClient prom.API
}

type ClustersType

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

func (*ClustersType) Get

func (cs *ClustersType) Get(name string) (*ClusterType, bool)

func (*ClustersType) Put

func (cs *ClustersType) Put(name string, cluster *ClusterType)

type DSReply added in v5.9.2

type DSReply struct {
	RequestID string `json:"request_id"`
	Data      struct {
		Items []struct {
			Name     string `json:"name"`
			Settings struct {
				PrometheusAddr  string `json:"prometheus.addr"`
				PrometheusBasic struct {
					PrometheusUser string `json:"prometheus.user"`
					PrometheusPass string `json:"prometheus.password"`
				} `json:"prometheus.basic"`
				Headers           map[string]string `json:"prometheus.headers"`
				PrometheusTimeout int64             `json:"prometheus.timeout"`
			} `json:"settings,omitempty"`
		} `json:"items"`
	} `json:"data"`
}

type PromOption added in v5.11.0

type PromOption struct {
	Url                 string
	User                string
	Pass                string
	Headers             []string
	Timeout             int64
	DialTimeout         int64
	MaxIdleConnsPerHost int
}

Jump to

Keyboard shortcuts

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