You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: postgres_exporter.go
-70Lines changed: 0 additions & 70 deletions
Original file line number
Diff line number
Diff line change
@@ -201,47 +201,6 @@ var builtinMetricMaps = map[string]map[string]ColumnMapping{
201
201
"mode": {LABEL, "Type of Lock", nil, nil},
202
202
"count": {GAUGE, "Number of locks", nil, nil},
203
203
},
204
-
"pg_stat_replication": {
205
-
"procpid": {DISCARD, "Process ID of a WAL sender process", nil, semver.MustParseRange("<9.2.0")},
206
-
"pid": {DISCARD, "Process ID of a WAL sender process", nil, semver.MustParseRange(">=9.2.0")},
207
-
"usesysid": {DISCARD, "OID of the user logged into cu WAL sender process", nil, nil},
208
-
"usename": {DISCARD, "Name of the user logged into cu WAL sender process", nil, nil},
209
-
"application_name": {DISCARD, "Name of the application that is connected to cu WAL sender", nil, nil},
210
-
"client_addr": {LABEL, "IP address of the client connected to cu WAL sender. If cu field is null, it indicates that the client is connected via a Unix socket on the server machine.", nil, nil},
211
-
"client_hostname": {DISCARD, "Host name of the connected client, as reported by a reverse DNS lookup of client_addr. This field will only be non-null for IP connections, and only when log_hostname is enabled.", nil, nil},
212
-
"client_port": {DISCARD, "TCP port number that the client is using for communication with cu WAL sender, or -1 if a Unix socket is used", nil, nil},
213
-
"backend_start": {DISCARD, "with time zone Time when cu process was started, i.e., when the client connected to cu WAL sender", nil, nil},
214
-
"backend_xmin": {DISCARD, "The current backend's xmin horizon.", nil, nil},
"sent_location": {DISCARD, "Last transaction log position sent on cu connection", nil, semver.MustParseRange("<10.0.0")},
217
-
"write_location": {DISCARD, "Last transaction log position written to disk by cu standby server", nil, semver.MustParseRange("<10.0.0")},
218
-
"flush_location": {DISCARD, "Last transaction log position flushed to disk by cu standby server", nil, semver.MustParseRange("<10.0.0")},
219
-
"replay_location": {DISCARD, "Last transaction log position replayed into the database on cu standby server", nil, semver.MustParseRange("<10.0.0")},
220
-
"sent_lsn": {DISCARD, "Last transaction log position sent on cu connection", nil, semver.MustParseRange(">=10.0.0")},
221
-
"write_lsn": {DISCARD, "Last transaction log position written to disk by cu standby server", nil, semver.MustParseRange(">=10.0.0")},
222
-
"flush_lsn": {DISCARD, "Last transaction log position flushed to disk by cu standby server", nil, semver.MustParseRange(">=10.0.0")},
223
-
"replay_lsn": {DISCARD, "Last transaction log position replayed into the database on cu standby server", nil, semver.MustParseRange(">=10.0.0")},
224
-
"sync_priority": {DISCARD, "Priority of cu standby server for being chosen as the synchronous standby", nil, nil},
225
-
"sync_state": {DISCARD, "Synchronous state of cu standby server", nil, nil},
226
-
"slot_name": {LABEL, "A unique, cluster-wide identifier for the replication slot", nil, semver.MustParseRange(">=9.2.0")},
227
-
"plugin": {DISCARD, "The base name of the shared object containing the output plugin cu logical slot is using, or null for physical slots", nil, nil},
228
-
"slot_type": {DISCARD, "The slot type - physical or logical", nil, nil},
229
-
"datoid": {DISCARD, "The OID of the database cu slot is associated with, or null. Only logical slots have an associated database", nil, nil},
230
-
"database": {DISCARD, "The name of the database cu slot is associated with, or null. Only logical slots have an associated database", nil, nil},
231
-
"active": {DISCARD, "True if cu slot is currently actively being used", nil, nil},
232
-
"active_pid": {DISCARD, "Process ID of a WAL sender process", nil, nil},
233
-
"xmin": {DISCARD, "The oldest transaction that cu slot needs the database to retain. VACUUM cannot remove tuples deleted by any later transaction", nil, nil},
234
-
"catalog_xmin": {DISCARD, "The oldest transaction affecting the system catalogs that cu slot needs the database to retain. VACUUM cannot remove catalog tuples deleted by any later transaction", nil, nil},
235
-
"restart_lsn": {DISCARD, "The address (LSN) of oldest WAL which still might be required by the consumer of cu slot and thus won't be automatically removed during checkpoints", nil, nil},
"pg_xlog_location_diff": {GAUGE, "Lag in bytes between master and slave", nil, semver.MustParseRange(">=9.2.0 <10.0.0")},
239
-
"pg_wal_lsn_diff": {GAUGE, "Lag in bytes between master and slave", nil, semver.MustParseRange(">=10.0.0")},
240
-
"confirmed_flush_lsn": {DISCARD, "LSN position a consumer of a slot has confirmed flushing the data received", nil, nil},
241
-
"write_lag": {DISCARD, "Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written it (but not yet flushed it or applied it). This can be used to gauge the delay that synchronous_commit level remote_write incurred while committing if this server was configured as a synchronous standby.", nil, semver.MustParseRange(">=10.0.0")},
242
-
"flush_lag": {DISCARD, "Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written and flushed it (but not yet applied it). This can be used to gauge the delay that synchronous_commit level remote_flush incurred while committing if this server was configured as a synchronous standby.", nil, semver.MustParseRange(">=10.0.0")},
243
-
"replay_lag": {DISCARD, "Time elapsed between flushing recent WAL locally and receiving notification that this standby server has written, flushed and applied it. This can be used to gauge the delay that synchronous_commit level remote_apply incurred while committing if this server was configured as a synchronous standby.", nil, semver.MustParseRange(">=10.0.0")},
244
-
},
245
204
"pg_stat_activity": {
246
205
"datname": {LABEL, "Name of cu database", nil, nil},
@@ -286,35 +245,6 @@ var queryOverrides = map[string][]OverrideQuery{
286
245
},
287
246
},
288
247
289
-
"pg_stat_replication": {
290
-
{
291
-
semver.MustParseRange(">=10.0.0"),
292
-
`
293
-
SELECT *,
294
-
(case pg_is_in_recovery() when 't' then null else pg_current_wal_lsn() end) AS pg_current_wal_lsn,
295
-
(case pg_is_in_recovery() when 't' then null else pg_wal_lsn_diff(pg_current_wal_lsn(), replay_lsn)::float end) AS pg_wal_lsn_diff
296
-
FROM pg_stat_replication
297
-
`,
298
-
},
299
-
{
300
-
semver.MustParseRange(">=9.2.0 <10.0.0"),
301
-
`
302
-
SELECT *,
303
-
(case pg_is_in_recovery() when 't' then null else pg_current_xlog_location() end) AS pg_current_xlog_location,
304
-
(case pg_is_in_recovery() when 't' then null else pg_xlog_location_diff(pg_current_xlog_location(), replay_location)::float end) AS pg_xlog_location_diff
305
-
FROM pg_stat_replication
306
-
`,
307
-
},
308
-
{
309
-
semver.MustParseRange("<9.2.0"),
310
-
`
311
-
SELECT *,
312
-
(case pg_is_in_recovery() when 't' then null else pg_current_xlog_location() end) AS pg_current_xlog_location
0 commit comments