mirror of
https://github.com/prometheus-community/postgres_exporter
synced 2025-04-26 04:58:05 +00:00
Remove commented code
Signed-off-by: Joe Adams <github@joeadams.io>
This commit is contained in:
parent
799f3e15b2
commit
8d6ce0558c
@ -61,21 +61,9 @@ func handleProbe(logger log.Logger, excludeDatabases []string) http.HandlerFunc
|
|||||||
|
|
||||||
// TODO(@sysadmind): Timeout
|
// TODO(@sysadmind): Timeout
|
||||||
|
|
||||||
// probeSuccessGauge := prometheus.NewGauge(prometheus.GaugeOpts{
|
|
||||||
// Name: "probe_success",
|
|
||||||
// Help: "Displays whether or not the probe was a success",
|
|
||||||
// })
|
|
||||||
// probeDurationGauge := prometheus.NewGauge(prometheus.GaugeOpts{
|
|
||||||
// Name: "probe_duration_seconds",
|
|
||||||
// Help: "Returns how long the probe took to complete in seconds",
|
|
||||||
// })
|
|
||||||
|
|
||||||
tl := log.With(logger, "target", target)
|
tl := log.With(logger, "target", target)
|
||||||
|
|
||||||
// start := time.Now()
|
|
||||||
registry := prometheus.NewRegistry()
|
registry := prometheus.NewRegistry()
|
||||||
// registry.MustRegister(probeSuccessGauge)
|
|
||||||
// registry.MustRegister(probeDurationGauge)
|
|
||||||
|
|
||||||
opts := []ExporterOpt{
|
opts := []ExporterOpt{
|
||||||
DisableDefaultMetrics(*disableDefaultMetrics),
|
DisableDefaultMetrics(*disableDefaultMetrics),
|
||||||
@ -83,7 +71,7 @@ func handleProbe(logger log.Logger, excludeDatabases []string) http.HandlerFunc
|
|||||||
AutoDiscoverDatabases(*autoDiscoverDatabases),
|
AutoDiscoverDatabases(*autoDiscoverDatabases),
|
||||||
WithUserQueriesPath(*queriesPath),
|
WithUserQueriesPath(*queriesPath),
|
||||||
WithConstantLabels(*constantLabelsList),
|
WithConstantLabels(*constantLabelsList),
|
||||||
ExcludeDatabases(*excludeDatabases),
|
ExcludeDatabases(excludeDatabases),
|
||||||
IncludeDatabases(*includeDatabases),
|
IncludeDatabases(*includeDatabases),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -29,8 +29,8 @@ type PGReplicationSlotCollector struct {
|
|||||||
log log.Logger
|
log log.Logger
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewPGReplicationSlotCollector(logger log.Logger) (Collector, error) {
|
func NewPGReplicationSlotCollector(config collectorConfig) (Collector, error) {
|
||||||
return &PGReplicationSlotCollector{log: logger}, nil
|
return &PGReplicationSlotCollector{log: config.logger}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
var pgReplicationSlot = map[string]*prometheus.Desc{
|
var pgReplicationSlot = map[string]*prometheus.Desc{
|
||||||
|
Loading…
Reference in New Issue
Block a user