postgresql/src
Peter Eisentraut c96de2ce17 Common function for percent placeholder replacement
There are a number of places where a shell command is constructed with
percent-placeholders (like %x).  It's cumbersome to have to open-code
this several times.  This factors out this logic into a separate
function.  This also allows us to ensure consistency for and document
some subtle behaviors, such as what to do with unrecognized
placeholders.

The unified handling is now that incorrect and unknown placeholders
are an error, where previously in most cases they were skipped or
ignored.  This affects the following settings:

- archive_cleanup_command
- archive_command
- recovery_end_command
- restore_command
- ssl_passphrase_command

The following settings are part of this refactoring but already had
stricter error handling and should be unchanged in their behavior:

- basebackup_to_shell.command

Reviewed-by: Nathan Bossart <nathandbossart@gmail.com>
Discussion: https://www.postgresql.org/message-id/flat/5238bbed-0b01-83a6-d4b2-7eb0562a054e%40enterprisedb.com
2023-01-11 10:42:35 +01:00
..
backend Common function for percent placeholder replacement 2023-01-11 10:42:35 +01:00
bin Fix typos in code and comments 2023-01-11 15:16:38 +09:00
common Common function for percent placeholder replacement 2023-01-11 10:42:35 +01:00
fe_utils Common function for percent placeholder replacement 2023-01-11 10:42:35 +01:00
include Common function for percent placeholder replacement 2023-01-11 10:42:35 +01:00
interfaces Update copyright for 2023 2023-01-02 15:00:37 -05:00
makefiles Update copyright for 2023 2023-01-02 15:00:37 -05:00
pl New header varatt.h split off from postgres.h 2023-01-10 05:54:36 +01:00
port Update copyright for 2023 2023-01-02 15:00:37 -05:00
template Use unnamed POSIX semaphores on Cygwin. 2023-01-06 10:33:28 +13:00
test Fix typos in code and comments 2023-01-11 15:16:38 +09:00
timezone Update copyright for 2023 2023-01-02 15:00:37 -05:00
tools Perform apply of large transactions by parallel workers. 2023-01-09 07:52:45 +05:30
tutorial Update copyright for 2023 2023-01-02 15:00:37 -05:00
.gitignore
DEVELOPERS
Makefile
Makefile.global.in autoconf: Move export_dynamic determination to configure 2022-12-06 18:55:28 -08:00
Makefile.shlib autoconf: Rely on ar supporting index creation 2022-10-07 11:53:39 -07:00
meson.build Update copyright for 2023 2023-01-02 15:00:37 -05:00
nls-global.mk Fix for make unportability 2022-07-13 09:15:01 +02:00