Re: [PATCH] Include application_name in "connection authorized" log message

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PATCH] Include application_name in "connection authorized" log message
Дата
Msg-id 24593.1533663162@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [PATCH] Include application_name in "connection authorized" log message  (Don Seiler <don@seiler.us>)
Ответы Re: [PATCH] Include application_name in "connection authorized" log message
Список pgsql-hackers
Don Seiler <don@seiler.us> writes:
> On Tue, Aug 7, 2018 at 11:29 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Well, if you're going to insist on that part, it's probably not worth
>> making the application_name GUC have inconsistent behavior.

> OK so just to make sure I understand:

> 1. We want to make a generic, central ascii-lobotomizing function similar
> to check_application_name that we can re-use there and for other checks (eg
> user name).
> 2. Change check_application_name to call this function (or just call this
> function instead of check_application_name()?)

check_application_name's API is dictated by the GUC check-hook interface,
and doesn't really make sense for this other use.  So the first part of
that, not the second.

> 3. Call this function when storing the value in the port struct.

I'm not sure where exactly is the most sensible place to call it,
but trying to minimize the number of places that know about this
kluge seems like a good principle.

            regards, tom lane


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: pg_dump: sortDumpableObjectsByTypeName() doesn't always do that
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Typo in doc or wrong EXCLUDE implementation