debug log in pg_archivecleanup - Mailing list pgsql-hackers

From Fujii Masao
Subject debug log in pg_archivecleanup
Date
Msg-id AANLkTilKokIBVfIPutiHyyxh8e0R3YYrHJwipK2Tuz_2@mail.gmail.com
Whole thread Raw
Responses Re: debug log in pg_archivecleanup  (Takahiro Itagaki <itagaki.takahiro@oss.ntt.co.jp>)
List pgsql-hackers
Hi,

Sometimes the postgres server log message and the pg_archivecleanup debug
message are output in the same line as follows. This is a little hard to
read.

-----------------------
LOG:  restored log file "00000001000000000000006B" from archive
pg_archivecleanup:  keep WAL file 000000010000000000000068 and later
pg_archivecleanup:  removing
"/dav/head-pgsql/act.arh/000000010000000000000048"LOG:  restored log
file "00000001000000000000006C" from archive

pg_archivecleanup:  removing "/dav/head-pgsql/act.arh/000000010000000000000061"
pg_archivecleanup:  removing "/dav/head-pgsql/act.arh/00000001000000000000004D"
pg_archivecleanup:  removing "/dav/head-pgsql/act.arh/00000001000000000000005C"
-----------------------

This is because pg_archivecleanup puts the line break "\n" in the head of
debug message. Why should we do so?

-----------------------if (debug)   fprintf(stderr, "\n%s:  removing \"%s\"", progname, WALFilePath);
-----------------------

Regards,

-- 
Fujii Masao
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center


pgsql-hackers by date:

Previous
From: Tim Bunce
Date:
Subject: PL/Perl function naming (was: release notes)
Next
From: Robert Haas
Date:
Subject: Re: Proposal for 9.1: WAL streaming from WAL buffers