collector

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2021 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collector

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

func New

func New(opts ...Option) *Collector

func (*Collector) Collect

func (c *Collector) Collect(ch chan<- prometheus.Metric)

func (*Collector) Describe

func (c *Collector) Describe(ch chan<- *prometheus.Desc)

type HTTPClient

type HTTPClient interface {
	Do(*http.Request) (*http.Response, error)
}

type Option

type Option func(cfg *config)

func WithHTTPClient

func WithHTTPClient(cli HTTPClient) Option

func WithLogger

func WithLogger(logger log.Logger) Option

func WithSoraURL

func WithSoraURL(url string) Option

func WithTimeout

func WithTimeout(timeout time.Duration) Option

Jump to

Keyboard shortcuts

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