FuelLabs / fuel-indexer

🗃 The Fuel indexer is a standalone service that can be used to index various components of the Fuel blockchain.
https://docs.fuel.network/docs/indexer/
140 stars 66 forks source link

enhancement: add postgres connection monitoring to the QA script #1433

Closed lostman closed 5 months ago

lostman commented 10 months ago

Description

We can periodically query Postgresql to see the number of active connections.

We had issuers related to too many connections before when I was benchmarking metering points, and lately: https://github.com/FuelLabs/fuel-indexer/issues/1430

psql -c "SELECT count(*) FROM pg_stat_activity WHERE state = 'active';"
 count
-------
     4
(1 row)
ra0x3 commented 10 months ago

@lostman

lostman commented 10 months ago

I think so. If it raises linearly with the number of indexers then there's an improvement to be made somewhere.