Re: Unified logging system for command-line programs

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Donald Dong <xdong(at)csumb(dot)edu>, Andres Freund <andres(at)anarazel(dot)de>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Unified logging system for command-line programs
Date: 2019-04-02 19:56:34
Message-ID: 20190402195634.GA14682@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I don't much like the code that does

pg_log_error("%s", something);

because then the string "%s" is marked for translation. Maybe we should
consider a variant that takes a straight string literal instead of a
sprintf-style fmt to avoid this problem. We'd do something like

pg_log_error_v(something);

which does not call _() within.

--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2019-04-02 20:17:20 Re: Unified logging system for command-line programs
Previous Message Alvaro Herrera 2019-04-02 19:42:55 Re: ToDo: show size of partitioned table