Re: Application name patch - v2

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: Application name patch - v2
Дата
Msg-id 200910200522.n9K5Mxd06277@momjian.us
обсуждение исходный текст
Ответ на Re: Application name patch - v2  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: Application name patch - v2
Список pgsql-hackers
Robert Haas wrote:
> > I do agree with Peter's concerns about limiting the character set of the
> > name string, and maybe there should be some sort of length limit too.
> 
> I don't have a strong feeling about this.  If limiting this to 7-bit
> characters solves some nasty encoding problems or something, then
> fine, but otherwise I think we can just escape what we emit into the
> log and say that users who log this information should have a
> sufficiently sophisticated log parser to cope with it.

Once problem I can imagine is someone with a long log_line prefix, like
'%t %a|', and assuming that the pipe is the end of the log_prefix
arguments.  If someone adds a pipe to the application name, log parsing
code will assume the %a pipe ends the log_line_prefix, and we have no
system of escaping things like pipes in log_line_prefix.

Effectively, if you use %a, there is no good way to terminate
log_line_prefix with a known unique character.

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + If your life is a hard drive, Christ can be your backup. +


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

Предыдущее
От: Greg Smith
Дата:
Сообщение: Re: per table random-page-cost?
Следующее
От: Itagaki Takahiro
Дата:
Сообщение: UTF8 with BOM support in psql