Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita2ac73e

Browse files
committed
Code review for backup manifest.
This commit prevents pg_basebackup from receiving backup_manifest filewhen --no-manifest is specified. Previously, when pg_basebackup waswriting a tarfile to stdout, it tried to receive backup_manifest file evenwhen --no-manifest was specified, and reported an error.Also remove unused -m option from pg_basebackup.Also fix typo in BASE_BACKUP command documentation.Author: Fujii MasaoReviewed-by: Michael Paquier, Robert HaasDiscussion:https://postgr.es/m/01e3ed3a-8729-5aaa-ca84-e60e3ca59db8@oss.nttdata.com
1 parent4a05a64 commita2ac73e

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

‎doc/src/sgml/protocol.sgml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2578,19 +2578,19 @@ The commands accepted in replication mode are:
25782578
</varlistentry>
25792579

25802580
<varlistentry>
2581-
<term><literal>MANIFEST</literal></term>
2581+
<term><literal>MANIFEST</literal> <replaceable>manifest_option</replaceable></term>
25822582
<listitem>
25832583
<para>
25842584
When this option is specified with a value of <literal>yes</literal>
2585-
or <literal>force-escape</literal>, a backup manifest is created
2585+
or <literal>force-encode</literal>, a backup manifest is created
25862586
and sent along with the backup. The manifest is a list of every
25872587
file present in the backup with the exception of any WAL files that
25882588
may be included. It also stores the size, last modification time, and
25892589
an optional checksum for each file.
2590-
A value of <literal>force-escape</literal> forces all filenames
2590+
A value of <literal>force-encode</literal> forces all filenames
25912591
to be hex-encoded; otherwise, this type of encoding is performed only
25922592
for files whose names are non-UTF8 octet sequences.
2593-
<literal>force-escape</literal> is intended primarily for testing
2593+
<literal>force-encode</literal> is intended primarily for testing
25942594
purposes, to be sure that clients which read the backup manifest
25952595
can handle this case. For compatibility with previous releases,
25962596
the default is <literal>MANIFEST 'no'</literal>.
@@ -2599,7 +2599,7 @@ The commands accepted in replication mode are:
25992599
</varlistentry>
26002600

26012601
<varlistentry>
2602-
<term><literal>MANIFEST_CHECKSUMS</literal></term>
2602+
<term><literal>MANIFEST_CHECKSUMS</literal> <replaceable>checksum_algorithm</replaceable></term>
26032603
<listitem>
26042604
<para>
26052605
Specifies the algorithm that should be applied to each file included

‎src/bin/pg_basebackup/pg_basebackup.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1211,7 +1211,7 @@ ReceiveTarFile(PGconn *conn, PGresult *res, int rownum)
12111211
* we're writing a tarfile to stdout, we don't have that option, so
12121212
* include it in the one tarfile we've got.
12131213
*/
1214-
if (strcmp(basedir,"-")==0)
1214+
if (strcmp(basedir,"-")==0&&manifest)
12151215
{
12161216
charheader[512];
12171217
PQExpBufferDatabuf;
@@ -2271,7 +2271,7 @@ main(int argc, char **argv)
22712271

22722272
atexit(cleanup_directories_atexit);
22732273

2274-
while ((c=getopt_long(argc,argv,"CD:F:r:RS:T:X:l:nNzZ:d:c:h:p:U:s:wWkvPm:",
2274+
while ((c=getopt_long(argc,argv,"CD:F:r:RS:T:X:l:nNzZ:d:c:h:p:U:s:wWkvP",
22752275
long_options,&option_index))!=-1)
22762276
{
22772277
switch (c)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp