Console Output
02:46:00 [2025-12-01T02:46:00.173Z] + export POSTGRES_DB=****
02:46:00 [2025-12-01T02:46:00.173Z] + export POSTGRES_USER=****
02:46:00 [2025-12-01T02:46:00.173Z] + export PGPASSWORD=****
02:46:00 [2025-12-01T02:46:00.173Z] + echo 📈 Running basic performance queries...
02:46:00 [2025-12-01T02:46:00.173Z] 📈 Running basic performance queries...
02:46:00 [2025-12-01T02:46:00.173Z] + docker exec -e PGPASSWORD=**** ****-**** psql -h localhost -U **** -d **** -c
02:46:00 [2025-12-01T02:46:00.173Z] -- Test basic query performance
02:46:00 [2025-12-01T02:46:00.174Z] EXPLAIN ANALYZE SELECT 1 as test_query;
02:46:00 [2025-12-01T02:46:00.174Z]
02:46:00 [2025-12-01T02:46:00.174Z] -- Test system catalog performance
02:46:00 [2025-12-01T02:46:00.174Z] EXPLAIN ANALYZE SELECT COUNT(*) FROM information_schema.tables;
02:46:00 [2025-12-01T02:46:00.174Z]
02:46:00 [2025-12-01T02:46:00.174Z] -- Test connection info
02:46:00 [2025-12-01T02:46:00.174Z] SELECT database_name, process_count FROM (
02:46:00 [2025-12-01T02:46:00.174Z] SELECT datname as database_name, COUNT(*) as process_count
02:46:00 [2025-12-01T02:46:00.174Z] FROM pg_stat_activity
02:46:00 [2025-12-01T02:46:00.174Z] GROUP BY datname
02:46:00 [2025-12-01T02:46:00.174Z] ) as activity_stats;
02:46:00 [2025-12-01T02:46:00.174Z]
02:46:00 [2025-12-01T02:46:00.426Z] QUERY PLAN
02:46:00 [2025-12-01T02:46:00.426Z] ---------------------------------------------------------------------------------------
02:46:00 [2025-12-01T02:46:00.426Z] Result (cost=0.00..0.01 rows=1 width=4) (actual time=0.005..0.009 rows=1.00 loops=1)
02:46:00 [2025-12-01T02:46:00.426Z] Planning:
02:46:00 [2025-12-01T02:46:00.426Z] Buffers: shared hit=3
02:46:00 [2025-12-01T02:46:00.426Z] Planning Time: 0.214 ms
02:46:00 [2025-12-01T02:46:00.426Z] Execution Time: 0.131 ms
02:46:00 [2025-12-01T02:46:00.426Z] (5 rows)
02:46:00 [2025-12-01T02:46:00.426Z]
02:46:00 [2025-12-01T02:46:00.426Z] QUERY PLAN
02:46:00 [2025-12-01T02:46:00.426Z] --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
02:46:00 [2025-12-01T02:46:00.427Z] Aggregate (cost=71.97..71.98 rows=1 width=8) (actual time=8.503..8.541 rows=1.00 loops=1)
02:46:00 [2025-12-01T02:46:00.427Z] Buffers: shared hit=28 read=12
02:46:00 [2025-12-01T02:46:00.427Z] -> Hash Left Join (cost=36.66..71.69 rows=112 width=0) (actual time=5.855..8.173 rows=215.00 loops=1)
02:46:00 [2025-12-01T02:46:00.427Z] Hash Cond: (c.reloftype = t.oid)
02:46:00 [2025-12-01T02:46:00.427Z] Buffers: shared hit=28 read=12
02:46:00 [2025-12-01T02:46:00.427Z] -> Hash Join (cost=1.09..34.58 rows=112 width=4) (actual time=0.491..2.109 rows=215.00 loops=1)
02:46:00 [2025-12-01T02:46:00.427Z] Hash Cond: (c.relnamespace = nc.oid)
02:46:00 [2025-12-01T02:46:00.427Z] Buffers: shared hit=22 read=1
02:46:00 [2025-12-01T02:46:00.427Z] -> Seq Scan on pg_class c (cost=0.00..32.67 rows=150 width=8) (actual time=0.080..0.936 rows=215.00 loops=1)
02:46:00 [2025-12-01T02:46:00.427Z] Filter: ((relkind = ANY ('{r,v,f,p}'::"char"[])) AND (pg_has_role(relowner, 'USAGE'::text) OR has_table_privilege(oid, 'SELECT, INSERT, UPDATE, DELETE, TRUNCATE, REFERENCES, TRIGGER'::text) OR has_any_column_privilege(oid, 'SELECT, INSERT, UPDATE, REFERENCES'::text)))
02:46:00 [2025-12-01T02:46:00.427Z] Rows Removed by Filter: 202
02:46:00 [2025-12-01T02:46:00.427Z] Buffers: shared hit=13 read=1
02:46:00 [2025-12-01T02:46:00.427Z] -> Hash (cost=1.05..1.05 rows=3 width=4) (actual time=0.337..0.343 rows=4.00 loops=1)
02:46:00 [2025-12-01T02:46:00.428Z] Buckets: 1024 Batches: 1 Memory Usage: 9kB
02:46:00 [2025-12-01T02:46:00.428Z] Buffers: shared hit=9
02:46:00 [2025-12-01T02:46:00.428Z] -> Seq Scan on pg_namespace nc (cost=0.00..1.05 rows=3 width=4) (actual time=0.126..0.297 rows=4.00 loops=1)
02:46:00 [2025-12-01T02:46:00.428Z] Filter: (NOT pg_is_other_temp_schema(oid))
02:46:00 [2025-12-01T02:46:00.428Z] Buffers: shared hit=9
02:46:00 [2025-12-01T02:46:00.428Z] -> Hash (cost=27.29..27.29 rows=662 width=4) (actual time=5.290..5.305 rows=639.00 loops=1)
02:46:00 [2025-12-01T02:46:00.428Z] Buckets: 1024 Batches: 1 Memory Usage: 31kB
02:46:00 [2025-12-01T02:46:00.428Z] Buffers: shared hit=6 read=11
02:46:00 [2025-12-01T02:46:00.428Z] -> Hash Join (cost=1.09..27.29 rows=662 width=4) (actual time=0.186..4.017 rows=639.00 loops=1)
02:46:00 [2025-12-01T02:46:00.428Z] Hash Cond: (t.typnamespace = nt.oid)
02:46:00 [2025-12-01T02:46:00.428Z] Buffers: shared hit=6 read=11
02:46:00 [2025-12-01T02:46:00.428Z] -> Seq Scan on pg_type t (cost=0.00..22.62 rows=662 width=8) (actual time=0.044..1.307 rows=639.00 loops=1)
02:46:00 [2025-12-01T02:46:00.428Z] Buffers: shared hit=5 read=11
02:46:00 [2025-12-01T02:46:00.428Z] -> Hash (cost=1.04..1.04 rows=4 width=4) (actual time=0.105..0.111 rows=4.00 loops=1)
02:46:00 [2025-12-01T02:46:00.429Z] Buckets: 1024 Batches: 1 Memory Usage: 9kB
02:46:00 [2025-12-01T02:46:00.429Z] Buffers: shared hit=1
02:46:00 [2025-12-01T02:46:00.429Z] -> Seq Scan on pg_namespace nt (cost=0.00..1.04 rows=4 width=4) (actual time=0.065..0.075 rows=4.00 loops=1)
02:46:00 [2025-12-01T02:46:00.429Z] Buffers: shared hit=1
02:46:00 [2025-12-01T02:46:00.429Z] Planning:
02:46:00 [2025-12-01T02:46:00.429Z] Buffers: shared hit=332 read=14
02:46:00 [2025-12-01T02:46:00.429Z] Planning Time: 10.595 ms
02:46:00 [2025-12-01T02:46:00.429Z] Execution Time: 9.749 ms
02:46:00 [2025-12-01T02:46:00.429Z] (35 rows)
02:46:00 [2025-12-01T02:46:00.429Z]
02:46:00 [2025-12-01T02:46:00.429Z] database_name | process_count
02:46:00 [2025-12-01T02:46:00.429Z] ---------------+---------------
02:46:00 [2025-12-01T02:46:00.429Z] | 8
02:46:00 [2025-12-01T02:46:00.429Z] **** | 1
02:46:00 [2025-12-01T02:46:00.429Z] authentik | 6
02:46:00 [2025-12-01T02:46:00.429Z] (3 rows)
02:46:00 [2025-12-01T02:46:00.429Z]