Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set - Mailing list pgsql-hackers

From Daniel Gustafsson
Subject Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set
Date
Msg-id D3038255-EAB5-4164-A9E3-7967B6738993@yesql.se
Whole thread Raw
In response to Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set  (bt23nguyent <bt23nguyent@oss.nttdata.com>)
Responses Re: Improve the log message output of basic_archive when basic_archive.archive_directory parameter is not set
List pgsql-hackers
> On 19 Sep 2023, at 11:21, bt23nguyent <bt23nguyent@oss.nttdata.com> wrote:

> Please let me know if you have any further suggestions that I can improve more.

+        *logdetail = pstrdup("WAL archiving failed because basic_archive.archive_directory is not set");

Nitpick: detail messages should end with a period per the error message style
guide [0].

-    archiving will proceed only when it returns <literal>true</literal>.
+    archiving will proceed only when it returns <literal>true</literal>. The
+    archiver may also emit the detail explaining how the module is not configured
+    to the sever log if the archive module has any.

I think this paragraph needs to be updated to include how the returned
logdetail is emitted, since it currently shows the WARNING without mentioning
the added detail in case returned.  It would also be good to mention that it
should be an allocated string which the caller can free.

--
Daniel Gustafsson

[0] https://www.postgresql.org/docs/devel/error-style-guide.html


pgsql-hackers by date:

Previous
From: Dean Rasheed
Date:
Subject: Re: Infinite Interval
Next
From: Amul Sul
Date:
Subject: Dump-restore loosing 'attnotnull' bit for DEFERRABLE PRIMARY KEY column(s).