From: | Ahsan Hadi <ahsan(dot)hadi(at)gmail(dot)com> |
---|---|
To: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Add session statistics to pg_stat_database |
Date: | 2020-07-23 13:16:02 |
Message-ID: | CA+9bhC+pGpp9xezwk-maOWmOCNg-0xm5OnPSSMmb2S=n7fTwMA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Jul 8, 2020 at 4:17 PM Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
wrote:
> Here is a patch that adds the following to pg_stat_database:
> - number of connections
>
Is it expected behaviour to not count idle connections? The connection is
included after it is aborted but not while it was idle.
> - number of sessions that were not disconnected regularly
> - total time spent in database sessions
> - total time spent executing queries
> - total idle in transaction time
>
> This is useful to check if connection pooling is working.
> It also helps to estimate the size of the connection pool
> required to keep the database busy, which depends on the
> percentage of the transaction time that is spent idling.
>
> Yours,
> Laurenz Albe
>
--
Highgo Software (Canada/China/Pakistan)
URL : http://www.highgo.ca
ADDR: 10318 WHALLEY BLVD, Surrey, BC
EMAIL: mailto: ahsan(dot)hadi(at)highgo(dot)ca
From | Date | Subject | |
---|---|---|---|
Next Message | Paul Förster | 2020-07-23 13:24:31 | Re: Building 12.3 from source on Mac |
Previous Message | Bharath Rupireddy | 2020-07-23 12:37:14 | Re: Parallel copy |