Skip to content

Commit 71630fd

Browse files
committed
fix: exclude pgbouncer, supabase_admin and supabase_storage_admin queries from user queries
Previous filters will be cleaned up after this change is validated in production.
1 parent 241f542 commit 71630fd

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

common.vars.pkr.hcl

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
postgres-version = "15.1.1.72"
1+
postgres-version = "15.1.1.73"

docker/all-in-one/opt/postgres_exporter/queries.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ supabase_usage_metrics:
285285
and query not like 'DELETE FROM net.http_request_queue%'
286286
and query not like '%source: project usage%'
287287
and query not like 'select name, setting from pg_settings where name in ($1, $2)%'
288-
and userid <> (select oid from pg_roles where rolname = 'authenticator')
288+
and userid not in (select oid from pg_roles where rolname in ('authenticator', 'pgbouncer', 'supabase_admin', 'supabase_storage_admin'))
289289
metrics:
290290
- user_queries_total:
291291
usage: "COUNTER"
@@ -312,7 +312,7 @@ pg_status:
312312
# specific to read replicas
313313
# for primary databases, all columns will always return a value of 0
314314
# ---
315-
# for checking replication lag (physical_replica_lag_second)
315+
# for checking replication lag (physical_replication_lag_seconds)
316316
# we firstly check if the replica is connected to its primary
317317
# and if last WAL received is equivalent to last WAL replayed
318318
# if so return 0

0 commit comments

Comments
 (0)