Re: Possible bug in logical replication.
Arseny Sher <a.sher@postgrespro.ru>
From: Arseny Sher <a.sher@postgrespro.ru>
To: Michael Paquier <michael@paquier.xyz>
Cc: Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>,
sawada.mshk@gmail.com, a.sher@postgrespro.ru, k.knizhnik@postgrespro.ru,
pgsql-hackers@lists.postgresql.org
Date: 2018-05-25T06:57:18Z
Lists: pgsql-hackers
Michael Paquier <michael@paquier.xyz> writes: > Maybe I am being too naive, but wouldn't it be just enough to update the > confirmed flush LSN to ctx->reader->ReadRecPtr? This way, the slot > advances up to the beginning of the last record where user wants to > advance, and not the beginning of the next record: Same problem should be handled at pg_logical_slot_get_changes_guts and apply worker feedback; and there is a convention that all commits since confirmed_flush must be decoded, so we risk decoding such boundary commit twice. -- Arseny Sher Postgres Professional: http://www.postgrespro.com The Russian Postgres Company
Commits
-
Rewrite comments in replication slot advance implementation
- 96bd49437cca 11.0 landed
- 1573995f5599 12.0 landed
-
Fix a couple of bugs with replication slot advancing feature
- f731cfa94c00 11.0 landed
-
Ability to advance replication slots
- 9c7d06d60680 11.0 cited