pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Block replication slot advance for these not yet reserving WAL 2+ messages / 1 participants [nested] [flat]
* pgsql: Block replication slot advance for these not yet reserving WAL @ 2018-07-11 00:13 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 2+ messages in thread From: Michael Paquier @ 2018-07-11 00:13 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Block replication slot advance for these not yet reserving WAL Such replication slots are physical slots freshly created without WAL being reserved, which is the default behavior, which have not been used yet as WAL consumption resources to retain WAL. This prevents advancing a slot to a position older than any WAL available, which could falsify calculations for WAL segment recycling. This also cleans up a bit the code, as ReplicationSlotRelease() would be called on ERROR, and improves error messages. Reported-by: Kyotaro Horiguchi Author: Michael Paquier Reviewed-by: Andres Freund, Álvaro Herrera, Kyotaro Horiguchi Discussion: https://postgr.es/m/20180626071305.GH31353@paquier.xyz Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/56a714721343e6f52c0b1b911c0f160592348e84 Modified Files -------------- contrib/test_decoding/expected/slot.out | 17 +++++++++++++++++ contrib/test_decoding/sql/slot.sql | 6 ++++++ doc/src/sgml/catalogs.sgml | 3 ++- src/backend/replication/slotfuncs.c | 13 ++++++++----- 4 files changed, 33 insertions(+), 6 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Block replication slot advance for these not yet reserving WAL @ 2018-07-11 00:13 Michael Paquier <michael@paquier.xyz> 0 siblings, 0 replies; 2+ messages in thread From: Michael Paquier @ 2018-07-11 00:13 UTC (permalink / raw) To: pgsql-committers@lists.postgresql.org Block replication slot advance for these not yet reserving WAL Such replication slots are physical slots freshly created without WAL being reserved, which is the default behavior, which have not been used yet as WAL consumption resources to retain WAL. This prevents advancing a slot to a position older than any WAL available, which could falsify calculations for WAL segment recycling. This also cleans up a bit the code, as ReplicationSlotRelease() would be called on ERROR, and improves error messages. Reported-by: Kyotaro Horiguchi Author: Michael Paquier Reviewed-by: Andres Freund, Álvaro Herrera, Kyotaro Horiguchi Discussion: https://postgr.es/m/20180626071305.GH31353@paquier.xyz Branch ------ REL_11_STABLE Details ------- https://git.postgresql.org/pg/commitdiff/9069eb95f48c8200f8589faf7adc5e324eed25cd Modified Files -------------- contrib/test_decoding/expected/slot.out | 17 +++++++++++++++++ contrib/test_decoding/sql/slot.sql | 6 ++++++ doc/src/sgml/catalogs.sgml | 3 ++- src/backend/replication/slotfuncs.c | 13 ++++++++----- 4 files changed, 33 insertions(+), 6 deletions(-) ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2018-07-11 00:13 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2018-07-11 00:13 pgsql: Block replication slot advance for these not yet reserving WAL Michael Paquier <michael@paquier.xyz> 2018-07-11 00:13 pgsql: Block replication slot advance for these not yet reserving WAL Michael Paquier <michael@paquier.xyz>
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