June 2024
Intermediate to advanced
456 pages
11h 34m
English
To explore current activity, query the pg_stat_activity system view that you saw earlier (see Getting Started with Observability). Besides client queries in pg_stat_activity, you’ll see your own current connection and any other running PostgreSQL background processes.
Filter on the application_name. Rails uses /bin/rails and a backend_type of client backend. Let’s explore some real activity.
To do that, let’s simulate application activity using Rideshare scripts, which will act as current activity using database connections. You’ll start up the rails server and run a script that sends HTTP requests to the API.
Run each of the following commands from different terminal windows in the Rideshare directory:
| | bin/rails ... |
Read now
Unlock full access