Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the new scrape config endpoint for the prometheus receiver #14464

Merged
Prev Previous commit
Next Next commit
Re-order
  • Loading branch information
jaronoff97 committed Oct 4, 2022
commit ff01d23d15f35a12598d293006bc0b3632709bfa
22 changes: 11 additions & 11 deletions receiver/prometheusreceiver/metrics_receiver.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,16 +48,16 @@ const (

// pReceiver is the type that provides Prometheus scraper/receiver functionality.
type pReceiver struct {
cfg *Config
consumer consumer.Metrics
cancelFunc context.CancelFunc
configLoaded chan struct{}
loadConfigOnce sync.Once

settings component.ReceiverCreateSettings
scrapeManager *scrape.Manager
discoveryManager *discovery.Manager
targetAllocatorStop chan bool
cfg *Config
consumer consumer.Metrics
cancelFunc context.CancelFunc
targetAllocatorStop chan struct{}
configLoaded chan struct{}
loadConfigOnce sync.Once

settings component.ReceiverCreateSettings
scrapeManager *scrape.Manager
discoveryManager *discovery.Manager
}

// New creates a new prometheus.Receiver reference.
Expand All @@ -67,7 +67,7 @@ func newPrometheusReceiver(set component.ReceiverCreateSettings, cfg *Config, ne
consumer: next,
settings: set,
configLoaded: make(chan struct{}),
targetAllocatorStop: make(chan bool, 1),
targetAllocatorStop: make(chan struct{}),
}
return pr
}
Expand Down