Re: logical replication: restart_lsn can go backwards (and more), seems broken since 9.4
Amit Kapila <amit.kapila16@gmail.com>
From: Amit Kapila <amit.kapila16@gmail.com>
To: Tomas Vondra <tomas@vondra.me>
Cc: Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>,
Masahiko Sawada <sawada.mshk@gmail.com>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Date: 2024-11-13T09:38:27Z
Lists: pgsql-hackers
On Tue, Nov 12, 2024 at 6:29 PM Tomas Vondra <tomas@vondra.me> wrote: > > Sure, maybe fixing LogicalIncreaseRestartDecodingForSlot() is enough to > fix this particular case. But I'd be happier if we could also add > asserts checking the LSN advances, to detect similar issues that we may > be unaware of yet. > As most of us lean towards fixing LogicalIncreaseRestartDecodingForSlot(), let's fix that in the HEAD and back branches. Separately we can consider other asserts just for HEAD that you think will make the code robust and help avoid such bugs in the future. -- With Regards, Amit Kapila.
Commits
-
Fix a possibility of logical replication slot's restart_lsn going backwards.
- e5ed873b1b4a 18.0 landed
- 568e78a653ee 17.2 landed
- f353911337cf 16.6 landed
- 91771b3fbbc3 15.10 landed
- 26c4e8968690 14.15 landed
- 15dc1abb17dd 13.18 landed
-
Introduce logical decoding.
- b89e151054a0 9.4.0 cited