Re: System username in pg_stat_activity

Поиск
Список
Период
Сортировка
Искать
От
Joe Conway
Тема
Re: System username in pg_stat_activity
Дата
Msg-id
671e76bf-4a81-4da7-a208-efb6ce81d3b4@joeconway.com
Ответ на
Список
Дерево обсуждения
System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Tom Lane <tgl@sss.pgh.pa.us>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Aleksander Alekseev <aleksander@timescale.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Joe Conway <mail@joeconway.com>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Andres Freund <andres@anarazel.de>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Aleksander Alekseev <aleksander@timescale.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Julien Rouhaud <rjuju123@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Re: System username in pg_stat_activity Magnus Hagander <magnus@hagander.net>
Re: System username in pg_stat_activity Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
On 1/10/24 08:59, Magnus Hagander wrote:
> On Wed, Jan 10, 2024 at 2:56 PM Bertrand Drouvot
>> I think it depends what we want the new field to reflect. If it is the exact
>> same thing as the SYSTEM_USER then I think it has to be text (as the SYSTEM_USER
>> is made of "auth_method:identity"). Now if we want it to be "only" the identity
>> part of it, then the `name` datatype would be fine. I'd vote for the exact same
>> thing as the SYSTEM_USER (means auth_method:identity).
> 
> I definitely think it should be the same. If it's not exactly the
> same, then it should be *two* columns, one with auth method and one
> with the name.
> 
> And thinking more about it maybe that's cleaner, because that makes it
> easier to do things like filter based on auth method?

+1 for the overall feature and +1 for two columns

>> > +     
>> > +      
>> > +       authname name
>> > +      
>> > +      
>> > +       The authentication method and identity (if any) that the user
>> > +       used to log in. It contains the same value as
>> > +        returns in the backend.
>> > +      
>> > +     
>>
>> I'm fine with auth_method:identity.
>>
>> > +            S.authname,
>>
>> What about using system_user as the field name? (because if we keep
>> auth_method:identity it's not really the authname anyway).
> 
> I was worried system_user or sysuser would both be confusing with the
> fact that we have usesysid -- which would reference a *different*
> sys...


I think if it is exactly "system_user" it would be pretty clearly a 
match for SYSTEM_USER


-- 
Joe Conway
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com



В списке pgsql-hackers по дате отправления
От: Bertrand Drouvot
Дата:
От: jian he
Дата:
FAQ