agora inbox for [email protected]
help / color / mirror / Atom feedinsert using select with limit
1937+ messages / 3 participants
[nested] [flat]
* insert using select with limit
@ 1999-12-10 10:57 Theo Kramer <[email protected]>
1999-12-10 15:41 ` Re: [HACKERS] insert using select with limit Tom Lane <[email protected]>
0 siblings, 1 reply; 1937+ messages in thread
From: Theo Kramer @ 1999-12-10 10:57 UTC (permalink / raw)
To: [email protected]
Hi
Just noticed that limit is ignored when using a select to insert
into a table.
Eg. insert into mytable (f1, f2) select f1, f2 from myothertable limit 10;
selects all records from myothertable.
Using the select with limit on it's own works fine.
Version 6.5.2 on RH6
--------
Regards
Theo
^ permalink raw reply [nested|flat] 1937+ messages in thread
* Re: [HACKERS] insert using select with limit
1999-12-10 10:57 insert using select with limit Theo Kramer <[email protected]>
@ 1999-12-10 15:41 ` Tom Lane <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Tom Lane @ 1999-12-10 15:41 UTC (permalink / raw)
To: Theo Kramer <[email protected]>; +Cc: [email protected]
Theo Kramer <[email protected]> writes:
> Just noticed that limit is ignored when using a select to insert
> into a table.
> Eg. insert into mytable (f1, f2) select f1, f2 from myothertable limit 10;
> selects all records from myothertable.
Ugh, you're right. Not sure if this will be easily fixable or not.
Worst case, the fix might have to wait for the long-planned query tree
redesign.
Or it might be a one-liner. Will look into it.
regards, tom lane
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v43 5/7] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index b0ecc769ee4..36950aea780 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--nzintiedl6o4kcyp
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v43-0006-Fix-a-few-problems-in-index-build-progress-repor.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
* [PATCH v44 04/10] Fix crash caused by involuntary decoding of unrelated relations
@ 2026-03-19 18:48 Álvaro Herrera <[email protected]>
0 siblings, 0 replies; 1937+ messages in thread
From: Álvaro Herrera @ 2026-03-19 18:48 UTC (permalink / raw)
Author: Srinath Reddy Sadipiralla <[email protected]>
---
src/backend/commands/cluster.c | 30 +++++++++++++++---------------
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/src/backend/commands/cluster.c b/src/backend/commands/cluster.c
index edb515d4b3e..b4acaeb6b93 100644
--- a/src/backend/commands/cluster.c
+++ b/src/backend/commands/cluster.c
@@ -2666,6 +2666,21 @@ repack_setup_logical_decoding(Oid relid)
*/
Assert(!ctx->fast_forward);
+ /* Avoid logical decoding of other relations. */
+ rel = table_open(relid, AccessShareLock);
+ repacked_rel_locator = rel->rd_locator;
+ toastrelid = rel->rd_rel->reltoastrelid;
+ if (OidIsValid(toastrelid))
+ {
+ Relation toastrel;
+
+ /* Avoid logical decoding of other TOAST relations. */
+ toastrel = table_open(toastrelid, AccessShareLock);
+ repacked_rel_toast_locator = toastrel->rd_locator;
+ table_close(toastrel, AccessShareLock);
+ }
+ table_close(rel, AccessShareLock);
+
DecodingContextFindStartpoint(ctx);
/*
@@ -2702,21 +2717,6 @@ repack_setup_logical_decoding(Oid relid)
"REPACK - change",
ALLOCSET_DEFAULT_SIZES);
- /* Avoid logical decoding of other relations. */
- rel = table_open(relid, AccessShareLock);
- repacked_rel_locator = rel->rd_locator;
- toastrelid = rel->rd_rel->reltoastrelid;
- if (OidIsValid(toastrelid))
- {
- Relation toastrel;
-
- /* Avoid logical decoding of other TOAST relations. */
- toastrel = table_open(toastrelid, AccessShareLock);
- repacked_rel_toast_locator = toastrel->rd_locator;
- table_close(toastrel, AccessShareLock);
- }
- table_close(rel, AccessShareLock);
-
/* The file will be set as soon as we have it opened. */
dstate->file = NULL;
--
2.47.3
--gwom7bl7ogtszo4k
Content-Type: text/x-diff; charset=utf-8
Content-Disposition: attachment;
filename="v44-0005-Rename-ChangeDest-to-ChangeContext-and-absorb-In.patch"
^ permalink raw reply [nested|flat] 1937+ messages in thread
end of thread, other threads:[~2026-03-19 18:48 UTC | newest]
Thread overview: 1937+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
1999-12-10 10:57 insert using select with limit Theo Kramer <[email protected]>
1999-12-10 15:41 ` Tom Lane <[email protected]>
2026-03-19 18: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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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 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]>
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox