Monitor Active Queries

You can monitor active queries for your SerenDB project from the Monitoring page in the SerenDB Console.

  1. In the SerenDB Console, select a project.

  2. Go to Monitoring.

  3. Select the Active Queries tab.

The Active Queries view displays up to 100 currently running queries for the selected Branch, Compute, and Database. Use the Refresh button to update the list with the latest active queries.

SerenDB active queries tab

The Active Queries view is powered by the pg_stat_activity Postgres system view, which is available in SerenDB by default. To run custom queries against the data collected by pg_stat_activity, you can use the SerenDB SQL Editor or any SQL client, such as psql.

For details on pg_stat_activity, see pg_stat_activity in the PostgreSQL documentation.

In SerenDB, the `pg_stat_activity` system view only holds data on currently running queries. Once a query completes, it no longer appears in the **Active Queries** view. If your SerenDB compute scales down to zero due to inactivity, there will be no active queries until a new connection is established and a query is run.

Last updated