Re: Fix slot synchronization with two_phase decoding enabled

From: shveta malik <shveta(dot)malik(at)gmail(dot)com>
To: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
Cc: Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, shveta malik <shveta(dot)malik(at)gmail(dot)com>
Subject: Re: Fix slot synchronization with two_phase decoding enabled
Date: 2025-06-12 04:49:57
Message-ID: CAJpy0uA88qiY1EXmtppchFNxGEqxaB1X_z6YLEmpM_f5j1i9UQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jun 11, 2025 at 11:31 PM Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:

>
> BTW have we addressed the point Amit mentioned before[1]?
>
> > The one more combination to consider is when someone takes a dump of
> > an older version and loads it into a newer version. For example, where
> > users dump from 17.5 and then restore in a newer version, say 17.6
> > (which has our fix), the restore will fail due to newer restrictions
> > added by this patch. Do we need to do anything about it?
>
> I think it could be a significant side-effect and we need to do
> something about that.
>

After giving it more thought, we have an opinion that this
side-effect/issue is unlikely to occur if users follow our
documentation properly.

The recommended approach for upgrading between minor versions is to
shut down the server and replace the binaries. See 'To update between
compatible versions' in [1].

Also it is recommended in docs that we use pg_dump from the newer
version of PostgreSQL. See 'It is recommended that you use the
pg_dump' in [2]. This particular recommendation is in the Upgrade doc.
If needed, we can make a similar recommendation in any of our failover
specific docs as well, mentioning this particular case.

In brief, our overall understanding is that a) pg_dump is mainly used
for major versions upgrade b) pg_dump of higher version is used.
Please let us know if your understanding is different here.

Beyond these steps, we could not find any better solution for the
pointed case. But we are open to exploring and implementing any
alternative solutions you may have. Feedback is most welcome here.

[1]: https://www.postgresql.org/docs/current/upgrading.html
[2]: https://www.postgresql.org/docs/current/upgrading.html#UPGRADING-VIA-PGDUMPALL

thanks
Shveta

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Konstantin Knizhnik 2025-06-12 05:03:22 Re: Non-reproducible AIO failure
Previous Message Shirisha Shirisha 2025-06-12 04:46:57 Proposal to allow DELETE/UPDATE on partitioned tables with unsupported foreign partitions