Skip to content

Commit

Permalink
collectors: do not start htlc monitor when htlc monitoring is disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
mrfelton committed Feb 6, 2024
1 parent a849499 commit bd9b085
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions collectors/prometheus.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,10 @@ func (p *PrometheusExporter) Start() error {

// Start the htlc monitor goroutine. This will subscribe to htlcs and
// update all of our routing-related metrics.
if err := p.htlcMonitor.start(); err != nil {
return err
if !p.monitoringCfg.DisableHtlc {
if err := p.htlcMonitor.start(); err != nil {
return err
}
}

// Finally, we'll launch the HTTP server that Prometheus will use to
Expand Down

0 comments on commit bd9b085

Please sign in to comment.