pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andres Freund <andres@anarazel.de>
To: Peter Geoghegan <pg@bowt.ie>
Cc: pgsql-hackers@postgresql.org
Subject: Re: pgsql: Delay commit status checks until freezing executes.
Date: Wed, 11 Jan 2023 15:06:56 -0800
Message-ID: <20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de> (raw)
In-Reply-To: <CAH2-Wzn=k55AGKhtqw+9ht2PZU9WBA-8nq-jqv=nR8wQ0AOtbw@mail.gmail.com>
References: <CAH2-WzmRTo_8_v=wkK3f08iVzuwVUQ3G=Ff00sFCK-Q+dPF2kg@mail.gmail.com>
	<20230104063325.32xq2gpnwlelhogo@awork3.anarazel.de>
	<CAH2-WzmYObiABaysh1SSNBgm0OPYm07DNzRq2vA1DgsOtrodFQ@mail.gmail.com>
	<20230104064740.6mnwcml6oqp3sxnr@awork3.anarazel.de>
	<CAH2-Wz=qKSEor8EHOzxhTDtxUacot0U=1hmnT=Rp8Q=OM4ggMw@mail.gmail.com>
	<CAH2-Wzn4bEEqgmaUQL3aJ73yM9gAeK-wE4ngi7kjRjLztb+P0w@mail.gmail.com>
	<20230107214756.fyrk735xkeetkkby@awork3.anarazel.de>
	<CAH2-WzmK0eLKZM0vDwnQ0iDsooYrEgKWGo1QWshD0ds11cc79A@mail.gmail.com>
	<20230108032549.xumh45fv6dicimmh@awork3.anarazel.de>
	<CAH2-Wzn=k55AGKhtqw+9ht2PZU9WBA-8nq-jqv=nR8wQ0AOtbw@mail.gmail.com>

Hi,

On 2023-01-11 14:29:25 -0800, Peter Geoghegan wrote:
> On Sat, Jan 7, 2023 at 7:25 PM Andres Freund <andres@anarazel.de> wrote:
> > Probably a good idea, although it doesn't neatly fit right now.
> 
> I'll leave it for now.
> 
> Attached is v2, which changes things based on your feedback. Would
> like to get this out of the way soon.

Makes sense. It's clearly an improvement.


> + * We can't use TransactionIdDidAbort here because it won't treat transactions
> + * that were in progress during a crash as aborted by now.  We determine that
> + * transactions aborted/crashed through process of elimination instead.

s/by now//?


>   * When using an MVCC snapshot, we rely on XidInMVCCSnapshot rather than
>   * TransactionIdIsInProgress, but the logic is otherwise the same: do not
> diff --git a/src/backend/access/transam/transam.c b/src/backend/access/transam/transam.c
> index 3a28dcc43..7629904bb 100644
> --- a/src/backend/access/transam/transam.c
> +++ b/src/backend/access/transam/transam.c
> @@ -110,7 +110,8 @@ TransactionLogFetch(TransactionId transactionId)
>   *		   transaction tree.
>   *
>   * See also TransactionIdIsInProgress, which once was in this module
> - * but now lives in procarray.c.
> + * but now lives in procarray.c, as well as comments at the top of
> + * heapam_visibility.c that explain how everything fits together.
>   * ----------------------------------------------------------------
>   */

+1

Greetings,

Andres Freund





view thread (24+ messages)  latest in thread

Message-ID: <20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de>
Permalink:  ../20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de/
Also on:    postgresql.org/message-id/20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de

 · 

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-committers@postgresql.org
  Cc: andres@anarazel.de, pg@bowt.ie, pgsql-hackers@postgresql.org
  Subject: Re: pgsql: Delay commit status checks until freezing executes.
  In-Reply-To: <20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de>
  References: <CAH2-WzmRTo_8_v=wkK3f08iVzuwVUQ3G=Ff00sFCK-Q+dPF2kg@mail.gmail.com> <20230104063325.32xq2gpnwlelhogo@awork3.anarazel.de> <CAH2-WzmYObiABaysh1SSNBgm0OPYm07DNzRq2vA1DgsOtrodFQ@mail.gmail.com> <20230104064740.6mnwcml6oqp3sxnr@awork3.anarazel.de> <CAH2-Wz=qKSEor8EHOzxhTDtxUacot0U=1hmnT=Rp8Q=OM4ggMw@mail.gmail.com> <CAH2-Wzn4bEEqgmaUQL3aJ73yM9gAeK-wE4ngi7kjRjLztb+P0w@mail.gmail.com> <20230107214756.fyrk735xkeetkkby@awork3.anarazel.de> <CAH2-WzmK0eLKZM0vDwnQ0iDsooYrEgKWGo1QWshD0ds11cc79A@mail.gmail.com> <20230108032549.xumh45fv6dicimmh@awork3.anarazel.de> <CAH2-Wzn=k55AGKhtqw+9ht2PZU9WBA-8nq-jqv=nR8wQ0AOtbw@mail.gmail.com> <20230111230656.q4ur4a2ww7plmaau@awork3.anarazel.de>

* 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