public inbox for [email protected]  
help / color / mirror / Atom feed
From: Tom Lane <[email protected]>
To: Matthias van de Meent <[email protected]>
Cc: David E. Wheeler <[email protected]>
Cc: Noah Misch <[email protected]>
Cc: Aleksander Alekseev <[email protected]>
Cc: pgsql-hackers <[email protected]>
Cc: Marco Slot <[email protected]>
Cc: Alvaro Herrera <[email protected]>
Cc: Christoph Berg <[email protected]>
Cc: Pavan Deolasee <[email protected]>
Subject: Re: Potential ABI breakage in upcoming minor releases
Date: Tue, 26 Nov 2024 13:24:35 -0500
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAEze2WgjQZJFnKwjRX9fUX0syW=qQbU+Y_4mkK9EN-oQB2D9_g@mail.gmail.com>
References: <[email protected]>
	<[email protected]>
	<[email protected]>
	<CAJ7c6TPcUJq_Bwo69f6ysRA1UbmSh_hOOEzJ2EvM0cW=3VEh5w@mail.gmail.com>
	<CAFMSG9Hy-2-8tfmmKy7noCbA3Yn1UY2SFUwYj7wHODTO8gDm8w@mail.gmail.com>
	<CAJ7c6TMCc85YoiSKex5Sztz6bEmV-0YqL7FY=_MxxcyoMGTDfQ@mail.gmail.com>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<[email protected]>
	<CAEze2WgjQZJFnKwjRX9fUX0syW=qQbU+Y_4mkK9EN-oQB2D9_g@mail.gmail.com>

Matthias van de Meent <[email protected]> writes:
> I would also add something like the following, to protect against
> corruption and deserialization errors of the catalog pg_node_tree
> fields, because right now the generated readfuncs.c code ignores field
> names, assumes ABI field order, and is generally quite sensitive to
> binary changes, which can cause corruption and/or errors during
> readback of those nodes:

> * If you update the contents of Nodes which are stored on disk as
> pg_node_tree, you also have to make sure that the read function for
> that node type is able to read both the old and the new serialized
> format.

No, actually that policy is "You cannot change the contents of
Node structs at all if they could appear in stored views, rules,
default expressions, etc".  We don't do catversion bumps in back
branches, which means that catalog contents have to be backwards
as well as forwards compatible across minor releases.

That's not really something that belongs under the heading of
ABI breaks, I think.  It's about "the on-disk representation of
catalogs is frozen within a release series", which extends to
more things than Nodes.  Still, maybe a parenthetical remark
wouldn't hurt.  Perhaps:

  (Keep in mind also that Node structs can't be changed at all
  if they might appear in stored views, rules, etc.)

			regards, tom lane






view thread (3+ messages)

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: Potential ABI breakage in upcoming minor releases
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox