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
}
Collector is a collector for prometheus
func NewCollector ¶
NewCollector create a collector
func (*Collector) Collect ¶
func (c *Collector) Collect(ch chan<- prometheus.Metric)
Collect collect metrics
func (*Collector) Describe ¶
func (c *Collector) Describe(ch chan<- *prometheus.Desc)
Describe describe metrics
type Metrics ¶
type Metrics struct { TotalScrapes prometheus.Counter ScrapeErrors *prometheus.CounterVec Error prometheus.Gauge }
Metrics is data in scraper
type Scraper ¶
type Scraper interface { Name() string Help() string Scrape(ctx context.Context, ds datastore.Datastore, ch chan<- prometheus.Metric) error }
Scraper is interface for scraping
type ScraperDatastore ¶
type ScraperDatastore struct{}
ScraperDatastore is scraper implement for datastore.Datastore
func (ScraperDatastore) Scrape ¶
func (ScraperDatastore) Scrape(ctx context.Context, ds datastore.Datastore, ch chan<- prometheus.Metric) error
Scrape scrape metrics
type ScraperGitHub ¶ added in v1.15.1
type ScraperGitHub struct{}
ScraperGitHub is scraper implement for GitHub
func (ScraperGitHub) Scrape ¶ added in v1.15.1
func (s ScraperGitHub) Scrape(ctx context.Context, ds datastore.Datastore, ch chan<- prometheus.Metric) error
Scrape scrape metrics
type ScraperMemory ¶ added in v1.9.10
type ScraperMemory struct{}
ScraperMemory is scraper implement for memory
func (ScraperMemory) Scrape ¶ added in v1.9.10
func (ScraperMemory) Scrape(ctx context.Context, ds datastore.Datastore, ch chan<- prometheus.Metric) error
Scrape scrape metrics
Click to show internal directories.
Click to hide internal directories.