Skip to content

Commit

Permalink
improve logging
Browse files Browse the repository at this point in the history
  • Loading branch information
nicksanford committed Sep 9, 2024
1 parent bbc1770 commit 644849c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions services/datamanager/builtin/capture/capture.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,12 @@ func (c *Capture) newCollectors(collectorConfigsByResource CollectorConfigsByRes
// We only use service-level tags.
cfg.Tags = config.Tags
if cfg.Disabled {
c.logger.Infof("%s disabled. config: %s", md.String(), format(cfg))
c.logger.Infof("collector disabled due to config `disabled` being true; collector: %s", md)
continue
}

if cfg.CaptureFrequencyHz <= 0 {
msg := "%s disabled due to `capture_frequency_hz` being less than or equal to zero. config: %#v"
c.logger.Warnf(msg, md.String(), format(cfg))
c.logger.Warnf("collector disabled due to config `capture_frequency_hz` being less than or equal to zero. collector: %s", md)
continue
}

Expand Down

0 comments on commit 644849c

Please sign in to comment.