Re: pg_upgrade does not upgrade pg_stat_statements properly - Mailing list pgsql-hackers

From Jan Wieck
Subject Re: pg_upgrade does not upgrade pg_stat_statements properly
Date
Msg-id 9d3d3311-2191-86f8-86b5-bc765ebd6a19@wi3ck.info
Whole thread Raw
In response to Re: pg_upgrade does not upgrade pg_stat_statements properly  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 7/30/21 1:05 PM, Tom Lane wrote:
> I don't see the need for it anyway.  What is different from just
> putting the update actions into an extension version upgrade
> script created according to the current rules, and then setting
> that new extension version as the default version in the extension
> build you ship for the new server version?

You are right. The real fix should actually be that an extension, that 
creates different objects depending on the major server version it is 
installed on, should not use the same version number for itself on those 
two server versions. It is actually wrong to have DO blocks that execute 
server version dependent sections in the CREATE EXTENSION scripts. 
However similar the code may be, it is intended for different server 
versions, so it is not the same version of the extension.


Regards, Jan

-- 
Jan Wieck



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pg_upgrade does not upgrade pg_stat_statements properly
Next
From: Tom Lane
Date:
Subject: Re: [PATCH] Hooks at XactCommand level