pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alban Hertroys <haramrae@gmail.com>
To: Karsten Hilbert <Karsten.Hilbert@gmx.net>
Cc: DAVID ROTH <adaptron@comcast.net>
Cc: Dominique Devienne <ddevienne@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Christophe Pettus <xof@thebuild.com>
Cc: Adrian Klaver <adrian.klaver@aklaver.com>
Cc: Laurenz Albe <laurenz.albe@cybertec.at>
Cc: David G. Johnston <david.g.johnston@gmail.com>
Cc: Martijn Tonies (Upscene Productions) <m.tonies@upscene.com>
Cc: pgsql-general@lists.postgresql.org
Subject: Re: Stored procedure code no longer stored in v14 and v15, changed behaviour
Date: Sun, 4 Dec 2022 18:05:30 +0100
Message-ID: <5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com> (raw)
In-Reply-To: <trinity-14b76257-6780-433b-8624-c2be32f0d603-1670097346999@3c-app-gmx-bap57>
References: <23DE96C56DFC404096553A22DDC5093B@MARTIJNWS>
	<CAKFQuwbYCk0oA3VT+ngEebBTBjdtGsVLEFOdPX2qqQJobA7rtg@mail.gmail.com>
	<1579912.1669908194@sss.pgh.pa.us>
	<CAFCRh--K2tahGetbJ_mtjiwvfFb9fF6SzjGnvbyoMKPr92FiTQ@mail.gmail.com>
	<c14b49a2043adafbe9589fab7af4eceb6199726c.camel@cybertec.at>
	<CAFCRh-8DBZdfq_r+5jX9s8XPGxrANCOuWffkBBadpRTm7VP-OA@mail.gmail.com>
	<bee36d64-84e3-2918-9183-6035e1e6e221@aklaver.com>
	<CAFCRh-_wTu8mdxurTgjVO0Z19Xs1sam0ZFQqdXAJ5eF+7NLkpA@mail.gmail.com>
	<0730410A-9C79-4EE2-B21B-3502445A8700@thebuild.com>
	<CAFCRh-_cNHc0K0zLy6s0H7kaXOwPkC0mK74aXTGA2YOqKi89FA@mail.gmail.com>
	<1697225.1669924271@sss.pgh.pa.us>
	<CAFCRh--6qhmGKy5j7RVEBWW=r3YCeRm=WogwKxEA6Nhzcc0uDg@mail.gmail.com>
	<1258414512.930087.1669990257195@connect.xfinity.com>
	<F472845F-DED3-4E7E-94DE-F4C65A1EECAA@gmail.com>
	<trinity-14b76257-6780-433b-8624-c2be32f0d603-1670097346999@3c-app-gmx-bap57>


> On 3 Dec 2022, at 20:55, Karsten Hilbert <Karsten.Hilbert@gmx.net> wrote:
> 
>> You would need to wrap the function creation calls into some automation to generate and store those diffs, comparing it back, etc, but that may be doable. I would also generate new diffs right after major version updates of the database (a before and after of the output of pg_get_functiondef, applied to the stored diff?).
> 
> I wonder whether that would tie the sanity check to a particular PG version.
> 
> I mean, pg_get_functiondef output being a server runtime artifact it might
> well change between server versions, no ?

I meant to write: “I would also generate new diffs right _before and_ after…”, precisely for that reason. The before patch should get you the last ’sane’ situation to get back to the source code. Next, you can diff that to the newly tokenised version after the upgrade.

It is a bit of a hassle, as you need to remember to do that before an upgrade, but at least you’d have something…

Alban Hertroys
--
If you can't see the forest for the trees,
cut the trees and you'll find there is no forest.






view thread (37+ messages)  latest in thread

Message-ID: <5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com>
Permalink:  ../5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com/
Also on:    postgresql.org/message-id/5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: haramrae@gmail.com, Karsten.Hilbert@gmx.net, adaptron@comcast.net, ddevienne@gmail.com, tgl@sss.pgh.pa.us, xof@thebuild.com, adrian.klaver@aklaver.com, laurenz.albe@cybertec.at, david.g.johnston@gmail.com, m.tonies@upscene.com
  Subject: Re: Stored procedure code no longer stored in v14 and v15, changed behaviour
  In-Reply-To: <5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com>
  References: <23DE96C56DFC404096553A22DDC5093B@MARTIJNWS> <CAKFQuwbYCk0oA3VT+ngEebBTBjdtGsVLEFOdPX2qqQJobA7rtg@mail.gmail.com> <1579912.1669908194@sss.pgh.pa.us> <CAFCRh--K2tahGetbJ_mtjiwvfFb9fF6SzjGnvbyoMKPr92FiTQ@mail.gmail.com> <c14b49a2043adafbe9589fab7af4eceb6199726c.camel@cybertec.at> <CAFCRh-8DBZdfq_r+5jX9s8XPGxrANCOuWffkBBadpRTm7VP-OA@mail.gmail.com> <bee36d64-84e3-2918-9183-6035e1e6e221@aklaver.com> <CAFCRh-_wTu8mdxurTgjVO0Z19Xs1sam0ZFQqdXAJ5eF+7NLkpA@mail.gmail.com> <0730410A-9C79-4EE2-B21B-3502445A8700@thebuild.com> <CAFCRh-_cNHc0K0zLy6s0H7kaXOwPkC0mK74aXTGA2YOqKi89FA@mail.gmail.com> <1697225.1669924271@sss.pgh.pa.us> <CAFCRh--6qhmGKy5j7RVEBWW=r3YCeRm=WogwKxEA6Nhzcc0uDg@mail.gmail.com> <1258414512.930087.1669990257195@connect.xfinity.com> <F472845F-DED3-4E7E-94DE-F4C65A1EECAA@gmail.com> <trinity-14b76257-6780-433b-8624-c2be32f0d603-1670097346999@3c-app-gmx-bap57> <5AF91A67-52F3-4D55-9402-CD4939027733@gmail.com>

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

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