Re: Potential ABI breakage in upcoming minor releases - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Potential ABI breakage in upcoming minor releases
Date
Msg-id 2500050.1731705196@sss.pgh.pa.us
Whole thread Raw
In response to Re: Potential ABI breakage in upcoming minor releases  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Potential ABI breakage in upcoming minor releases
List pgsql-hackers
After some quick checking with "git diff", I can confirm that
there is no ABI break for ResultRelInfo in v12 or v13.  To fix
it in v14-v17, we could do this:

diff --git a/src/include/nodes/execnodes.h b/src/include/nodes/execnodes.h
index 418c81f4be..17b0ec5138 100644
--- a/src/include/nodes/execnodes.h
+++ b/src/include/nodes/execnodes.h
@@ -484,6 +484,9 @@ typedef struct ResultRelInfo
     /* Have the projection and the slots above been initialized? */
     bool        ri_projectNewInfoValid;
 
+    /* updates do LockTuple() before oldtup read; see README.tuplock */
+    bool        ri_needLockTagTuple;
+
     /* triggers to be fired, if any */
     TriggerDesc *ri_TrigDesc;
 
@@ -592,9 +595,6 @@ typedef struct ResultRelInfo
      * one of its ancestors; see ExecCrossPartitionUpdateForeignKey().
      */
     List       *ri_ancestorResultRels;
-
-    /* updates do LockTuple() before oldtup read; see README.tuplock */
-    bool        ri_needLockTagTuple;
 } ResultRelInfo;
 
 /* ----------------

(The next-to-last field varies across branches, but this general
idea will work.)  In other words, put ri_needLockTagTuple in the
same place it is in HEAD.  In other words, our current guidelines
for preserving ABI compatibility actually *created* this disaster,
because the HEAD change was fine from an ABI standpoint but what
was done in back branches was not.  So we do need to rethink how
that's worded.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Potential ABI breakage in upcoming minor releases
Next
From: Heikki Linnakangas
Date:
Subject: Re: Optimizing FastPathTransferRelationLocks()