Refactor cpu collector to use perflib instead of WMI.

This commit is contained in:
Calle Pettersson
2019-04-05 15:59:40 +02:00
parent 462a136673
commit 33879449a2
42 changed files with 1681 additions and 234 deletions

View File

@@ -1687,7 +1687,7 @@ func (c *MSSQLCollector) execute(name string, fn mssqlCollectorFunc, ch chan<- p
// Collect sends the metric values for each metric
// to the provided prometheus Metric channel.
func (c *MSSQLCollector) Collect(ch chan<- prometheus.Metric) error {
func (c *MSSQLCollector) Collect(ctx *ScrapeContext, ch chan<- prometheus.Metric) error {
wg := sync.WaitGroup{}
enabled := mssqlExpandEnabledCollectors(*mssqlEnabledCollectors)