user308827
user308827

Reputation: 22011

Finding number of open connections to postgres database

I connect to a postgres database hosted on AWS. Is there a way to find out the number of open connections to that database using python API?

Upvotes: 0

Views: 79

Answers (1)

BryceH
BryceH

Reputation: 2798

I assume this is for RDS. There is no direct way via the AWS API. You could potentially get it from CloudWatch but you'd be better off connecting to the database and getting the count that way by querying pg_stat_activity.

Upvotes: 1

Related Questions