Re: Add support for logging the current role - Mailing list pgsql-hackers

From Stephen Frost
Subject Re: Add support for logging the current role
Date
Msg-id 20110113012605.GO4933@tamriel.snowman.net
Whole thread Raw
In response to Re: Add support for logging the current role  (Stephen Frost <sfrost@snowman.net>)
Responses Re: Add support for logging the current role  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
* Stephen Frost (sfrost@snowman.net) wrote:
> Erm, really?  Ok, fine, maybe you didn't have log_line_prefix set
> correctly the first time you needed the information, but after you
> discover that you *don't know*, you're going to be looking for an option
> to let you get that information for the future.

Oh, yeah, and honestly, the above is the reason I'm after this myself- I
was having a difficult time figuring out which of 300-odd users a given
error was happening for and was annoyed that I couldn't figure out what
role it was.  The web server logs in with a 'general' role that doesn't
inherit anything and then has to 'set role' to whatever role the user
authenticated with.  After that 'set role' happens, we've got no way to
know from the logs who is impacted by a given error.

Guess I'm just trying to say that I didn't write this patch as an
academic exercise but rather because it solves a real world problem for
me.
Thanks,
    Stephen

pgsql-hackers by date:

Previous
From: Stephen Frost
Date:
Subject: Re: Add support for logging the current role
Next
From: Tom Lane
Date:
Subject: Re: Add support for logging the current role