mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Implement NOWAIT option for BASE_BACKUP command
Specifying this option makes the server not wait for the xlog to be archived, or emit a warning that it can't, instead leaving the responsibility with the client. This is useful when the log is being streamed using the streaming protocol in parallel with the backup, without having log archiving enabled.
This commit is contained in:
@@ -71,6 +71,7 @@ Node *replication_parse_result;
|
||||
%token K_LABEL
|
||||
%token K_PROGRESS
|
||||
%token K_FAST
|
||||
%token K_NOWAIT
|
||||
%token K_WAL
|
||||
%token K_START_REPLICATION
|
||||
|
||||
@@ -107,7 +108,7 @@ identify_system:
|
||||
;
|
||||
|
||||
/*
|
||||
* BASE_BACKUP [LABEL '<label>'] [PROGRESS] [FAST] [WAL]
|
||||
* BASE_BACKUP [LABEL '<label>'] [PROGRESS] [FAST] [WAL] [NOWAIT]
|
||||
*/
|
||||
base_backup:
|
||||
K_BASE_BACKUP base_backup_opt_list
|
||||
@@ -142,6 +143,11 @@ base_backup_opt:
|
||||
$$ = makeDefElem("wal",
|
||||
(Node *)makeInteger(TRUE));
|
||||
}
|
||||
| K_NOWAIT
|
||||
{
|
||||
$$ = makeDefElem("nowait",
|
||||
(Node *)makeInteger(TRUE));
|
||||
}
|
||||
;
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user