new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Supabase · Database · all subjects

connection-pooling/monitoring

4 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Connection usage monitoring in dashboard

You can track connection usage from the Observability section in your project dashboard. There are three key reports: Database Connections (shows total active connections by role including direct and pooled connections), Dedicated Pooler Client Connections (shows active client connections to PgBouncer), and Shared Pooler (Supavisor) Client Connections (shows active client connections to Supavisor). The Roles page is not real-time and shows the connection count from the last refresh.

Query to count connections by application and user

This query counts connections by application and user name: ```sql select count(usename), count(application_name), application_name, usename from pg_stat_ssl join pg_stat_activity on pg_stat_ssl.pid = pg_stat_activity.pid group by usename, application_name; ```

Query to view all database connections

This query displays all connections with detailed information: ```sql SELECT pg_stat_activity.pid, ssl AS ssl_connection, datname AS database, usename AS connected_role, application_name, client_addr, query, query_start, state, backend_start FROM pg_stat_ssl JOIN pg_stat_activity ON pg_stat_ssl.pid = pg_stat_activity.pid; ```

Baseline active connections from Supabase services

Even if your application isn't making queries, some Supabase services keep persistent connections to your database. For example, Storage, PostgREST, and the health checker all maintain long-lived connections. You usually see a small baseline of active connections from these services when the app is idle.

Give your agent this brain