Re: pg_upgrade does not upgrade pg_stat_statements properly

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Dave Cramer <davecramer(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_upgrade does not upgrade pg_stat_statements properly
Date: 2021-07-14 19:33:42
Message-ID: CAKFQuwZWQf--+Gj7Ld9x+XQ_Bsvj+OE0_A01jj6GhQ451H4ZGA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jul 14, 2021 at 12:21 PM Dave Cramer <davecramer(at)gmail(dot)com> wrote:

>
> On Wed, 14 Jul 2021 at 15:09, David G. Johnston <
> david(dot)g(dot)johnston(at)gmail(dot)com> wrote:
>
>>
>> Something like, "... because the installed extensions will be copied from
>> the old cluster during the upgrade."
>>
>
> This is still rather opaque. Without intimate knowledge of what changes
> have occurred in each extension I have installed; how would I know what I
> have to fix after the upgrade.
>

The point of this behavior is that you don't have to fix anything after an
upgrade - so long as your current extension version works on the new
cluster. If you are upgrading in such a way that the current extension and
new cluster are not compatible you need to not do that. Upgrade instead to
a lesser version where they are compatible. Then upgrade your extension to
its newer version, changing any required user code that such an upgrade
requires, then upgrade the server again.

David J.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2021-07-14 19:34:10 Re: Replacing pg_depend PIN entries with a fixed range check
Previous Message Tom Lane 2021-07-14 19:26:03 Re: [PATCH] Hooks at XactCommand level