pg.ddx.io pgsql-committers@postgresql.org mailing list archive
help / color / mirror / Atom feedpgsql: Flexible options for BASE_BACKUP.
3+ messages / 3 participants
[nested] [flat]
* pgsql: Flexible options for BASE_BACKUP.
@ 2021-10-05 15:54 Robert Haas <rhaas@postgresql.org>
2021-10-05 18:33 ` Re: pgsql: Flexible options for BASE_BACKUP. Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 1 reply; 3+ messages in thread
From: Robert Haas @ 2021-10-05 15:54 UTC (permalink / raw)
To: pgsql-committers@lists.postgresql.org
Flexible options for BASE_BACKUP.
Previously, BASE_BACKUP used an entirely hard-coded syntax, but that's
hard to extend. Instead, adopt the same kind of syntax we've used for
SQL commands such as VACUUM, ANALYZE, COPY, and EXPLAIN, where it's
not necessary for all of the option names to be parser keywords.
In the new syntax, most of the options now take an optional Boolean
argument. To match our practice in other in places, the options which
the old syntax called NOWAIT and NOVERIFY_CHECKSUMS options are in the
new syntax called WAIT and VERIFY_CHECKUMS, and the default value is
false. In the new syntax, the FAST option has been replaced by a
CHECKSUM option whose value may be 'fast' or 'spread'.
This commit does not remove support for the old syntax. It just adds
the new one as an additional option, and makes pg_basebackup prefer
the new syntax when the server is new enough to support it.
Patch by me, reviewed and tested by Fabien Coelho, Sergei Kornilov,
Fujii Masao, and Tushar Ahuja.
Discussion: http://postgr.es/m/CA+TgmobAczXDRO_Gr2euo_TxgzaH1JxbNxvFx=HYvBinefNH8Q@mail.gmail.com
Discussion: http://postgr.es/m/CA+TgmoZGwR=ZVWFeecncubEyPdwghnvfkkdBe9BLccLSiqdf9Q@mail.gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/0ba281cb4bf9f5f65529dfa4c8282abb734dd454
Modified Files
--------------
doc/src/sgml/protocol.sgml | 67 ++++++++++++++----------
src/backend/replication/basebackup.c | 51 +++++++++++-------
src/backend/replication/repl_gram.y | 97 ++++++++++++++++++++++++++++++-----
src/bin/pg_basebackup/pg_basebackup.c | 71 ++++++++++++++++---------
src/bin/pg_basebackup/streamutil.c | 61 ++++++++++++++++++++++
src/bin/pg_basebackup/streamutil.h | 12 +++++
6 files changed, 276 insertions(+), 83 deletions(-)
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: pgsql: Flexible options for BASE_BACKUP.
2021-10-05 15:54 pgsql: Flexible options for BASE_BACKUP. Robert Haas <rhaas@postgresql.org>
@ 2021-10-05 18:33 ` Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-10-05 19:31 ` Re: pgsql: Flexible options for BASE_BACKUP. Robert Haas <robertmhaas@gmail.com>
0 siblings, 1 reply; 3+ messages in thread
From: Alvaro Herrera @ 2021-10-05 18:33 UTC (permalink / raw)
To: Robert Haas <rhaas@postgresql.org>; +Cc: pgsql-committers@lists.postgresql.org
On 2021-Oct-05, Robert Haas wrote:
> In the new syntax, the FAST option has been replaced by a
> CHECKSUM option whose value may be 'fast' or 'spread'.
This was supposed to be CHECKPOINT --
| K_FAST
{
$$ = makeDefElem("checkpoint",
(Node *)makeString("fast"), -1);
}
--
Álvaro Herrera 39°49'30"S 73°17'W — https://www.EnterpriseDB.com/
"Cuando no hay humildad las personas se degradan" (A. Christie)
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: pgsql: Flexible options for BASE_BACKUP.
2021-10-05 15:54 pgsql: Flexible options for BASE_BACKUP. Robert Haas <rhaas@postgresql.org>
2021-10-05 18:33 ` Re: pgsql: Flexible options for BASE_BACKUP. Alvaro Herrera <alvherre@alvh.no-ip.org>
@ 2021-10-05 19:31 ` Robert Haas <robertmhaas@gmail.com>
0 siblings, 0 replies; 3+ messages in thread
From: Robert Haas @ 2021-10-05 19:31 UTC (permalink / raw)
To: Alvaro Herrera <alvherre@alvh.no-ip.org>; +Cc: pgsql-committers <pgsql-committers@lists.postgresql.org>
On Tue, Oct 5, 2021 at 2:33 PM Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
> On 2021-Oct-05, Robert Haas wrote:
> > In the new syntax, the FAST option has been replaced by a
> > CHECKSUM option whose value may be 'fast' or 'spread'.
>
> This was supposed to be CHECKPOINT --
>
> | K_FAST
> {
> $$ = makeDefElem("checkpoint",
> (Node *)makeString("fast"), -1);
> }
Oops. *blush*
--
Robert Haas
EDB: http://www.enterprisedb.com
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2021-10-05 19:31 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-10-05 15:54 pgsql: Flexible options for BASE_BACKUP. Robert Haas <rhaas@postgresql.org>
2021-10-05 18:33 ` Alvaro Herrera <alvherre@alvh.no-ip.org>
2021-10-05 19:31 ` Robert Haas <robertmhaas@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox