1
0
mirror of https://github.com/postgres/postgres.git synced 2025-09-02 04:21:28 +03:00

Allow BASE_BACKUP to be throttled

A new MAX_RATE option allows imposing a limit to the network transfer
rate from the server side.  This is useful to limit the stress that
taking a base backup has on the server.

pg_basebackup is now able to specify a value to the server, too.

Author: Antonin Houska

Patch reviewed by Stefan Radomski, Andres Freund, Zoltán Böszörményi,
Fujii Masao, and Álvaro Herrera.
This commit is contained in:
Alvaro Herrera
2014-02-27 18:55:57 -03:00
parent 1161d895d8
commit ef5856fd9b
7 changed files with 306 additions and 20 deletions

View File

@@ -14,6 +14,13 @@
#include "nodes/replnodes.h"
/*
* Minimum and maximum values of MAX_RATE option in BASE_BACKUP command.
*/
#define MAX_RATE_LOWER 32
#define MAX_RATE_UPPER 1048576
extern void SendBaseBackup(BaseBackupCmd *cmd);
#endif /* _BASEBACKUP_H */