Re: Proposal to sync SET ROLE and pg_stat_activity

Поиск
Список
Период
Сортировка
Искать
От
Bernd Helmle
Тема
Re: Proposal to sync SET ROLE and pg_stat_activity
Дата
Msg-id
D366E0AF519EB334417C8695@imhotep.credativ.de
Список
Дерево обсуждения
Re: Proposal to sync SET ROLE and pg_stat_activity Bernd Helmle <mailings@oopsware.de>
Re: Proposal to sync SET ROLE and pg_stat_activity Grant Finnemore <grant@guruhut.com>
Re: Proposal to sync SET ROLE and pg_stat_activity Alvaro Herrera <alvherre@commandprompt.com>
Re: Proposal to sync SET ROLE and pg_stat_activity Grant Finnemore <grant@guruhut.com>
--On Mittwoch, August 27, 2008 09:35:03 +0200 Grant Finnemore 
 wrote:

> I have a session pool, where all connections to the database are
> obtained as a superuser. On issuing connections to the client, we
> invoke either SET ROLE or SET SESSION AUTHORIZATION and switch to
> a role with less permissions. This means that we don't have to
> reserve a connection per user, and we can still use the database
> access restrictions.


But you have to ensure that your session pool is smaller than 
max_connections, since this will eat up superuser_reserved_connections and 
would make administrator intervention  impossible under certain 
circumstances.

And why do you need to hack pg_stat_activity, isn't it possible to plug 
your own view in?

--  Thanks
                   Bernd

В списке pgsql-hackers по дате отправления
От: Tom Lane
Дата:
Сообщение: Re: TODO <-> Commitfest
От: Grant Finnemore
Дата:
FAQ