From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
Subject: | pgsql: Replace replication slot's invalidated_at LSN with an enum |
Date: | 2023-04-08 05:08:10 |
Message-ID: | E1pl0o5-001zIr-Jo@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
Replace replication slot's invalidated_at LSN with an enum
This is mainly useful because the upcoming logical-decoding-on-standby feature
adds further reasons for invalidating slots, and we don't want to end up with
multiple invalidated_* fields, or check different attributes.
Eventually we should consider not resetting restart_lsn when invalidating a
slot due to max_slot_wal_keep_size. But that's a user visible change, so left
for later.
Increases SLOT_VERSION, due to the changed field (with a different alignment,
no less).
Reviewed-by: "Drouvot, Bertrand" <bertranddrouvot(dot)pg(at)gmail(dot)com>
Reviewed-by: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Reviewed-by: Melanie Plageman <melanieplageman(at)gmail(dot)com>
Discussion: https://postgr.es/m/20230407075009.igg7be27ha2htkbt@awork3.anarazel.de
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/15f8203a5975d6b9b78e2c64e213ed964b50c044
Modified Files
--------------
src/backend/replication/slot.c | 28 ++++++++++++++++++++++++----
src/backend/replication/slotfuncs.c | 8 +++-----
src/include/replication/slot.h | 15 +++++++++++++--
src/tools/pgindent/typedefs.list | 1 +
4 files changed, 41 insertions(+), 11 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2023-04-08 05:35:04 | pgsql: Prevent use of invalidated logical slot in CreateDecodingContext |
Previous Message | Thomas Munro | 2023-04-08 04:35:13 | pgsql: Add io_direct setting (developer-only). |