Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewStandardGo ¶
func NewStandardProcess ¶
Types ¶
type ColumnMapping ¶
type ColumnMapping struct {
// contains filtered or unexported fields
}
ColumnMapping is the user-friendly representation of a prometheus descriptor map.
func (*ColumnMapping) UnmarshalYAML ¶
func (cm *ColumnMapping) UnmarshalYAML(unmarshal func(interface{}) error) error
UnmarshalYAML implements yaml.Unmarshaller.
type ColumnUsage ¶
type ColumnUsage int
ColumnUsage should be one of several enum values which describe how a queried row is to be converted to a Prometheus metric.
func (*ColumnUsage) UnmarshalYAML ¶
func (cu *ColumnUsage) UnmarshalYAML(unmarshal func(interface{}) error) error
UnmarshalYAML implements the yaml.Unmarshaller interface.
type CustomQuery ¶
type CustomQuery struct {
// contains filtered or unexported fields
}
CustomQuery - contains MySQL query parsed from YAML file.
type MetricMap ¶
type MetricMap struct {
// contains filtered or unexported fields
}
MetricMap stores the prometheus metric description which a given column will be mapped to by the collector.
type MetricMapNamespace ¶
type MetricMapNamespace struct {
// contains filtered or unexported fields
}
MetricMapNamespace groups metric maps under a shared set of labels.
type MetricResolution ¶
type MetricResolution string
const ( LR MetricResolution = "lr" MR MetricResolution = "mr" HR MetricResolution = "hr" )
type ScrapeCustomQuery ¶
type ScrapeCustomQuery struct {
Resolution MetricResolution
}
ScrapeCustomQuery colects the metrics from custom queries.
func (ScrapeCustomQuery) Help ¶
func (scq ScrapeCustomQuery) Help() string
Help returns additional information about Scraper.
func (ScrapeCustomQuery) Scrape ¶
func (scq ScrapeCustomQuery) Scrape(ctx context.Context, db *sql.DB, ch chan<- prometheus.Metric, logger log.Logger) error
Scrape collects data.
func (ScrapeCustomQuery) Version ¶
func (scq ScrapeCustomQuery) Version() float64
Version of MySQL from which scraper is available.
type ScrapeGlobalStatus ¶
type ScrapeGlobalStatus struct{}
ScrapeGlobalStatus collects from `SHOW GLOBAL STATUS`.
func (ScrapeGlobalStatus) Help ¶
func (ScrapeGlobalStatus) Help() string
Help describes the role of the Scraper.
func (ScrapeGlobalStatus) Name ¶
func (ScrapeGlobalStatus) Name() string
Name of the Scraper. Should be unique.
func (ScrapeGlobalStatus) Scrape ¶
func (ScrapeGlobalStatus) Scrape(ctx context.Context, db *sql.DB, ch chan<- prometheus.Metric, logger log.Logger) error
Scrape collects data from database connection and sends it over channel as prometheus metric.
func (ScrapeGlobalStatus) Version ¶
func (ScrapeGlobalStatus) Version() float64
Version of MySQL from which scraper is available.
type ScrapeInnodbCmp ¶
type ScrapeInnodbCmp struct{}
ScrapeInnodbCmp collects from `information_schema.innodb_cmp`.
func (ScrapeInnodbCmp) Help ¶
func (ScrapeInnodbCmp) Help() string
Help describes the role of the Scraper.
func (ScrapeInnodbCmp) Name ¶
func (ScrapeInnodbCmp) Name() string
Name of the Scraper. Should be unique.
func (ScrapeInnodbCmp) Scrape ¶
func (ScrapeInnodbCmp) Scrape(ctx context.Context, db *sql.DB, ch chan<- prometheus.Metric, logger log.Logger) error
Scrape collects data from database connection and sends it over channel as prometheus metric.
func (ScrapeInnodbCmp) Version ¶
func (ScrapeInnodbCmp) Version() float64
Version of MySQL from which scraper is available.
type ScrapeInnodbCmpMem ¶
type ScrapeInnodbCmpMem struct{}
ScrapeInnodbCmp collects from `information_schema.innodb_cmp`.
func (ScrapeInnodbCmpMem) Help ¶
func (ScrapeInnodbCmpMem) Help() string
Help describes the role of the Scraper.
func (ScrapeInnodbCmpMem) Name ¶
func (ScrapeInnodbCmpMem) Name() string
Name of the Scraper. Should be unique.
func (ScrapeInnodbCmpMem) Scrape ¶
func (ScrapeInnodbCmpMem) Scrape(ctx context.Context, db *sql.DB, ch chan<- prometheus.Metric, logger log.Logger) error
Scrape collects data from database connection and sends it over channel as prometheus metric.
func (ScrapeInnodbCmpMem) Version ¶
func (ScrapeInnodbCmpMem) Version() float64
Version of MySQL from which scraper is available.
type ScrapeProcesslist ¶
type ScrapeProcesslist struct{}
ScrapeProcesslist collects from `information_schema.processlist`.
func (ScrapeProcesslist) Help ¶
func (ScrapeProcesslist) Help() string
Help describes the role of the Scraper.
func (ScrapeProcesslist) Name ¶
func (ScrapeProcesslist) Name() string
Name of the Scraper. Should be unique.
func (ScrapeProcesslist) Scrape ¶
func (ScrapeProcesslist) Scrape(ctx context.Context, db *sql.DB, ch chan<- prometheus.Metric, logger log.Logger) error
Scrape collects data from database connection and sends it over channel as prometheus metric.
func (ScrapeProcesslist) Version ¶
func (ScrapeProcesslist) Version() float64
Version of MySQL from which scraper is available.