File tree Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Expand file tree Collapse file tree 2 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ docker run --net=host -e DATA_SOURCE_NAME="postgresql://postgres:password@localh
34
34
Use the flag if you don't want to scrape ` pg_settings ` .
35
35
36
36
* ` auto-discover-databases `
37
- Whether to discover the databases on a server dynamically .
37
+ Enable discovering databases automatically .
38
38
39
39
* ` extend.query-path `
40
40
Path to a YAML file containing custom queries to run. Check out [ ` queries.yaml ` ] ( queries.yaml )
@@ -102,7 +102,7 @@ The following environment variables configure the exporter:
102
102
Use the flag if you don't want to scrape ` pg_settings ` . Value can be ` true ` or ` false ` . Defauls is ` false ` .
103
103
104
104
* ` PG_EXPORTER_AUTO_DISCOVER_DATABASES `
105
- Whether to discover the databases on a server dynamically . Value can be ` true ` or ` false ` . Defauls is ` false ` .
105
+ Enable discovering databases automatically . Value can be ` true ` or ` false ` . Defauls is ` false ` .
106
106
107
107
* ` PG_EXPORTER_EXTEND_QUERY_PATH `
108
108
Path to a YAML file containing custom queries to run. Check out [ ` queries.yaml ` ] ( queries.yaml )
Original file line number Diff line number Diff line change @@ -76,10 +76,6 @@ const (
76
76
serverLabelName = "server"
77
77
)
78
78
79
- func init () {
80
- prometheus .MustRegister (version .NewCollector ("postgres_exporter" ))
81
- }
82
-
83
79
type MetricResolution string
84
80
85
81
const (
@@ -1718,14 +1714,14 @@ func main() {
1718
1714
exporter .servers .Close ()
1719
1715
}()
1720
1716
1717
+ prometheus .MustRegister (exporter )
1718
+
1721
1719
version .Branch = Branch
1722
1720
version .BuildDate = BuildDate
1723
1721
version .Revision = Revision
1724
1722
version .Version = VersionShort
1725
1723
prometheus .MustRegister (version .NewCollector ("postgres_exporter" ))
1726
1724
1727
- prometheus .MustRegister (exporter )
1728
-
1729
1725
psCollector := prometheus .NewProcessCollector (prometheus.ProcessCollectorOpts {})
1730
1726
goCollector := prometheus .NewGoCollector ()
1731
1727
You can’t perform that action at this time.
0 commit comments