Expose waitforarchive option through pg_stop_backup()
Stephen Frost <sfrost@snowman.net>
Expose waitforarchive option through pg_stop_backup() Internally, we have supported the option to either wait for all of the WAL associated with a backup to be archived, or to return immediately. This option is useful to users of pg_stop_backup() as well, when they are reading the stop backup record position and checking that the WAL they need has been archived independently. This patch adds an additional, optional, argument to pg_stop_backup() which allows the user to indicate if they wish to wait for the WAL to be archived or not. The default matches current behavior, which is to wait. Author: David Steele, with some minor changes, doc updates by me. Reviewed by: Takayuki Tsunakawa, Fujii Masao Discussion: https://postgr.es/m/758e3fd1-45b4-5e28-75cd-e9e7f93a4c02@pgmasters.net
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/backup.sgml | modified | +12 −1 |
| doc/src/sgml/func.sgml | modified | +8 −2 |
| src/backend/access/transam/xlog.c | modified | +2 −1 |
| src/backend/access/transam/xlogfuncs.c | modified | +10 −2 |
| src/backend/catalog/system_views.sql | modified | +7 −1 |
| src/include/catalog/catversion.h | modified | +1 −1 |
| src/include/catalog/pg_proc.h | modified | +1 −1 |
Documentation touched
Discussion
- PATCH: Make pg_stop_backup() archive wait optional 31 messages · 2017-02-28 → 2017-04-04