From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: deferred writing of two-phase state files adds fragility |
Date: | 2024-12-04 18:01:42 |
Message-ID: | CA+Tgmoa7ytdSS1U2ZXNHr+mNgVwhnwOWp2g3pkm1Vu-RvA8M+w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Dec 4, 2024 at 12:58 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> > On Wed, Dec 4, 2024 at 12:19 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> >> Could we fix it so ROLLBACK TRANSACTION removes the GID from the
> >> list of prepared xacts that need to be written out? Then we'd
> >> no longer have a pending requirement to read the broken WAL record.
>
> > That would be nice, but I'm not sure that it's possible. As currently
> > implemented, FinishPreparedTransaction() always reads the two-phase
> > state data either from the two-phase file or the WAL, whether it's
> > committing or rolling back.
>
> I'm not following. FinishPreparedTransaction is not what's preventing
> checkpoints or holding back the VACUUM horizon. What is doing that
> is the in-memory fake PGPROC representing the prepared transaction
> (I forget the exact terminology). I'm suggesting that we could have
> some way to nuke one of those without properly cleaning up the
> prepared xact. Maybe it'd need to be invoked via a different command
> than ROLLBACK TRANSACTION.
Yes, that we could do. Perhaps it could be added to pg_surgery.
--
Robert Haas
EDB: http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Matheus Alcantara | 2024-12-04 18:44:51 | SCRAM pass-through authentication for postgres_fdw |
Previous Message | Tom Lane | 2024-12-04 17:58:43 | Re: deferred writing of two-phase state files adds fragility |