mirror of
https://github.com/lightningnetwork/lnd.git
synced 2024-11-19 18:10:34 +01:00
f5eeb05e0a
Start the Prometheus exporter in rpcserver.go if monitoring is enabled through the build tag. Also allow users to specify what address they want the Prometheus exporter to be listening on.
20 lines
587 B
Go
20 lines
587 B
Go
// +build !monitoring
|
|
|
|
package lncfg
|
|
|
|
// Prometheus configures the Prometheus exporter when monitoring is enabled.
|
|
// Monitoring is currently disabled.
|
|
type Prometheus struct{}
|
|
|
|
// DefaultPrometheus is the default configuration for the Prometheus metrics
|
|
// exporter when monitoring is enabled. Monitoring is currently disabled.
|
|
func DefaultPrometheus() Prometheus {
|
|
return Prometheus{}
|
|
}
|
|
|
|
// Enabled returns whether or not Prometheus monitoring is enabled. Monitoring
|
|
// is currently disabled, so Enabled will always return false.
|
|
func (p *Prometheus) Enabled() bool {
|
|
return false
|
|
}
|