Skip to content

Commit ec6998f

Browse files
author
Dementii Priadko
committed
Merge branch '13-remove-1-from-pg_stat_statements-dashboard' into 'main'
Remove "others" (a.k.a. "-1) aggregation from pg_stat_statements metric in prometheus Closes #13 See merge request postgres-ai/postgres_ai!42
2 parents 019f08d + e466b61 commit ec6998f

File tree

1 file changed

+0
-48
lines changed

1 file changed

+0
-48
lines changed

config/pgwatch-prometheus/metrics.yml

Lines changed: 0 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -901,30 +901,6 @@ metrics:
901901
temp_bytes_read::int8 as temp_bytes_read,
902902
temp_bytes_written::int8 as temp_bytes_written
903903
from ranked_statements
904-
where rn <= 500
905-
union all
906-
select
907-
'tail_dummy_user' as tag_user,
908-
current_database() as tag_datname,
909-
-1 as tag_queryid,
910-
sum(calls)::int8 as calls,
911-
sum(plans_total)::int8 as plans_total,
912-
sum(exec_time_total)::int8 as exec_time_total,
913-
sum(plan_time_total)::int8 as plan_time_total,
914-
sum(rows)::int8 as rows,
915-
sum(shared_bytes_hit_total)::int8 as shared_bytes_hit_total,
916-
sum(shared_bytes_read_total)::int8 as shared_bytes_read_total,
917-
sum(shared_bytes_dirtied_total)::int8 as shared_bytes_dirtied_total,
918-
sum(shared_bytes_written_total)::int8 as shared_bytes_written_total,
919-
sum(block_read_total)::int8 as block_read_total,
920-
sum(block_write_total)::int8 as block_write_total,
921-
sum(wal_records)::int8 as wal_records,
922-
sum(wal_fpi)::int8 as wal_fpi,
923-
sum(wal_bytes)::int8 as wal_bytes,
924-
sum(temp_bytes_read)::int8 as temp_bytes_read,
925-
sum(temp_bytes_written)::int8 as temp_bytes_written
926-
from ranked_statements
927-
where rn > 500
928904
17: |
929905
WITH ranked_statements as (
930906
select
@@ -973,30 +949,6 @@ metrics:
973949
temp_bytes_read::int8 as temp_bytes_read,
974950
temp_bytes_written::int8 as temp_bytes_written
975951
from ranked_statements
976-
where rn <= 500
977-
union all
978-
select
979-
'tail_dummy_user' as tag_user,
980-
current_database() as tag_datname,
981-
-1 as tag_queryid,
982-
sum(calls)::int8 as calls,
983-
sum(plans_total)::int8 as plans_total,
984-
sum(exec_time_total)::int8 as exec_time_total,
985-
sum(plan_time_total)::int8 as plan_time_total,
986-
sum(rows)::int8 as rows,
987-
sum(shared_bytes_hit_total)::int8 as shared_bytes_hit_total,
988-
sum(shared_bytes_read_total)::int8 as shared_bytes_read_total,
989-
sum(shared_bytes_dirtied_total)::int8 as shared_bytes_dirtied_total,
990-
sum(shared_bytes_written_total)::int8 as shared_bytes_written_total,
991-
sum(block_read_total)::int8 as block_read_total,
992-
sum(block_write_total)::int8 as block_write_total,
993-
sum(wal_records)::int8 as wal_records,
994-
sum(wal_fpi)::int8 as wal_fpi,
995-
sum(wal_bytes)::int8 as wal_bytes,
996-
sum(temp_bytes_read)::int8 as temp_bytes_read,
997-
sum(temp_bytes_written)::int8 as temp_bytes_written
998-
from ranked_statements
999-
where rn > 500
1000952
gauges:
1001953
- calls
1002954
- plans_total

0 commit comments

Comments
 (0)