Skip to content

Commit

Permalink
Merge pull request #112 from evevseev/fix-labels-hot-reload
Browse files Browse the repository at this point in the history
Update labels on hot-reload
  • Loading branch information
czerwonk authored Jun 9, 2024
2 parents 926ca78 + 1c53166 commit 3eab260
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions collector.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ func (p *pingCollector) UpdateConfig(cfg *config.Config) {
p.mutex.Lock()
defer p.mutex.Unlock()
p.cfg.Targets = cfg.Targets
p.customLabels = newCustomLabelSet(cfg.Targets)
p.createDesc()
}

func (p *pingCollector) Describe(ch chan<- *prometheus.Desc) {
Expand Down

0 comments on commit 3eab260

Please sign in to comment.