1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-28 18:48:04 +03:00

Exit from base backups when shutdown is requested

When the exit waits until the whole backup completes, it may take
a very long time.

In passing, add back an error check in the main loop so we detect
clients that disconnect much earlier if the backup is large.
This commit is contained in:
Magnus Hagander
2011-01-14 12:36:45 +01:00
parent 52948169bc
commit 688423d004
3 changed files with 23 additions and 9 deletions

View File

@@ -53,6 +53,8 @@ extern WalSndCtlData *WalSndCtl;
/* global state */
extern bool am_walsender;
extern volatile sig_atomic_t walsender_shutdown_requested;
extern volatile sig_atomic_t walsender_ready_to_stop;
/* user-settable parameters */
extern int WalSndDelay;