agora inbox for [email protected]
help / color / mirror / Atom feedRe: foreign keys for array/period contains relationships
1935+ messages / 3 participants
[nested] [flat]
* Re: foreign keys for array/period contains relationships
@ 2011-03-20 15:18 Rod Taylor <[email protected]>
0 siblings, 1 reply; 1935+ messages in thread
From: Rod Taylor @ 2011-03-20 15:18 UTC (permalink / raw)
To: Peter Eisentraut <[email protected]>; +Cc: pgsql-hackers
On Mon, Oct 25, 2010 at 15:11, Peter Eisentraut <[email protected]> wrote:
> Example #4: PK is period, FK is timestamp. FK must be contained in some
> PK period.
>
> CREATE TABLE pk (a period PRIMARY KEY, ...);
>
> CREATE TABLE fk (x timestamp REFERENCES pk (a), ...);
>
> As above, we can probably arrange the operator knowledge to make these
> checks. But I think additionally, you'd need an exclusion constraint on
> the PK side to ensure nonoverlapping arrays/periods so that on
> update/delete restrict as well as cascading deletes work.
>
Additional interesting examples involve IP network containment using
> inet/cidr or ip4/ip4r. There, you'd probably need additional syntax to
> tell the system explicitly which operators to use.
>
There are a large number of use-cases for this type of foreign key with
geometry ( PostGIS ) types as well. Point references Area or Line, Area
references Area, etc.
^ permalink raw reply [nested|flat] 1935+ messages in thread
* Re: foreign keys for array/period contains relationships
@ 2011-03-20 20:17 Andrew Tipton <[email protected]>
parent: Rod Taylor <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Andrew Tipton @ 2011-03-20 20:17 UTC (permalink / raw)
To: Rod Taylor <[email protected]>; +Cc: pgsql-hackers
>
> On Mon, Oct 25, 2010 at 15:11, Peter Eisentraut <[email protected]> wrote:
>
>> Example #4: PK is period, FK is timestamp. FK must be contained in some
>> PK period.
>>
>> CREATE TABLE pk (a period PRIMARY KEY, ...);
>>
>> CREATE TABLE fk (x timestamp REFERENCES pk (a), ...);
>>
>> As above, we can probably arrange the operator knowledge to make these
>> checks. But I think additionally, you'd need an exclusion constraint on
>> the PK side to ensure nonoverlapping arrays/periods so that on
>> update/delete restrict as well as cascading deletes work.
>>
>
> Additional interesting examples involve IP network containment using
>> inet/cidr or ip4/ip4r. There, you'd probably need additional syntax to
>> tell the system explicitly which operators to use.
>>
>
> There are a large number of use-cases for this type of foreign key with
> geometry ( PostGIS ) types as well. Point references Area or Line, Area
> references Area, etc.
>
You may be interested in an experiment I did late last year, where I did a
bit of playing around in the system catalogs to create this kind of
relationship. Turns out that the RI infrastructure stores the oid of the
equality operators it uses in pg_constraint, and after creating a normal
foreign key constraint it can be updated to change these operators. Of
course, Bad Things can probably happen if you violate assumptions that the
RI code depends on. I suspect that the most important one is that a child
row must reference exactly one parent row.
For establishing a point-contained-in-box relationship, the parent-eq-parent
operator is BOX && BOX and the child-eq-parent operator is POINT <@ BOX.
The parent-eq-child operator is BOX @> POINT, which is the commutator of
child-eq-parent. Declaring an exclusion constraint on the parent column
using the && operator guarantees that the <@ operator can only match a
single parent row.
If we're able to teach Postgres about these operator relationships -- that
is, && combined with <@ satisfies the restriction that a child row can only
reference one parent row -- extending the RI creation code to support this
kind of a relationship looks to be fairly straightforward.
(I've attached a small .sql script which demonstrates this for the POINT <@
BOX case.)
-Andrew
Attachments:
[text/x-sql] rihack.sql (2.0K, ../../[email protected]/3-rihack.sql)
download | inline:
-- relational integrity hacking: attempting to create non-equality FK
-- relationships.
-- parent relation has (non-overlapping) BOX keys, child relation has POINT
-- keys.
BEGIN;
DROP SCHEMA IF EXISTS rihack CASCADE;
CREATE SCHEMA rihack;
SET search_path TO rihack, public;
CREATE DOMAIN INTBOX AS BOX CHECK (
(VALUE[0])[0] = ROUND((VALUE[0])[0]) AND
(VALUE[0])[1] = ROUND((VALUE[0])[1]) AND
(VALUE[1])[0] = ROUND((VALUE[1])[0]) AND
(VALUE[1])[1] = ROUND((VALUE[1])[1])
);
CREATE DOMAIN INTPOINT AS POINT CHECK (
VALUE[0] = ROUND(VALUE[0]) AND VALUE[1] = ROUND(VALUE[1])
);
CREATE TABLE boxes (
id SERIAL PRIMARY KEY,
region INTBOX NOT NULL,
name TEXT NOT NULL,
CONSTRAINT boxes_cannot_overlap EXCLUDE USING gist (region WITH &&)
);
CREATE TABLE points (
region_id INTEGER REFERENCES boxes,
poi INTPOINT NOT NULL,
score INTEGER NOT NULL
);
-- Now, what we want to do is define an FK relationship:
-- FOREIGN KEY points.poi REFERENCES boxes.region WITH <@
-- We're going to hijack the existing constraint on the points table:
-- FOREIGN KEY points.region_id REFERENCES boxes.id WITH =
-- oids of operators:
-- POINT <@ BOX 511
-- BOX @> POINT 433 [commutator of op 511]
-- BOX ~= BOX 499
-- POINT ~= POINT 510
UPDATE pg_constraint SET conkey='{2}',
confkey='{2}',
conpfeqop='{433}',
conppeqop='{499}',
conffeqop='{510}'
WHERE conname='points_region_id_fkey';
-- these should all work:
INSERT INTO boxes (region, name) VALUES (box(point(2,2), point(5,5)), 'A');
INSERT INTO boxes (region, name) VALUES (box(point(7,7), point(10,10)), 'A');
INSERT INTO points (region_id, poi, score) VALUES (1, point(3,3), 10);
INSERT INTO points (region_id, poi, score) VALUES (1, point(4,4), 5);
INSERT INTO points (region_id, poi, score) VALUES (2, point(8,8), 15);
COMMIT;
-- this should fail:
INSERT INTO points (region_id, poi, score) VALUES (1, point(1,1), 15);
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1935+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1935+ messages in thread
end of thread, other threads:[~2026-03-19 18:48 UTC | newest]
Thread overview: 1935+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2011-03-20 15:18 Re: foreign keys for array/period contains relationships Rod Taylor <[email protected]>
2011-03-20 20:17 ` Andrew Tipton <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
2026-03-19 18:48 [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations Álvaro Herrera <[email protected]>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox