Re: limiting connections per user/database - Mailing list pgsql-patches

From Petr Jelínek
Subject Re: limiting connections per user/database
Date
Msg-id 42BFE6E1.2070708@parba.cz
Whole thread Raw
In response to Re: limiting connections per user/database  (Petr Jelínek <pjmodos@parba.cz>)
List pgsql-patches
So now I have it all working including brand new alter database (this
would have to be doublechecked by somebody from core team) and using
proc array to get number of backends per database and per user.

My only concer now is that userid in PGPROC, does anybody have anything
against it ?

And one more thing about userid, at the time MyProc is inserted to proc
array we don't know userid, so I am now updating MyProc as soon as I
know it (check for connection limit is done afterwards).
There is another solution I know of - I could use flatfiles to get
userid before MyProc is stored in proc array (which is how we get
MyDatabaseId anyway).
What of those solutions is better in your opinion ?

Oh and atm those limits are not enforced for superusers, any objections ?

--
Regards
Petr Jelinek (PJMODOS)
www.parba.cz


pgsql-patches by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: COPY FROM performance improvements
Next
From: Atsushi Ogawa
Date:
Subject: regexp_replace