Re: what does this mean: "running xacts with xcnt == 0"

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: what does this mean: "running xacts with xcnt == 0"
Date: 2014-11-12 14:56:01
Message-ID: 20141112145601.GY1791@alvin.alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund wrote:
> Hi,
>
> On 2014-11-12 09:03:40 -0500, Peter Eisentraut wrote:
> > Could someone translate this detail message to English:
> >
> > ereport(LOG,
> > (errmsg("logical decoding found consistent point at %X/%X",
> > (uint32) (lsn >> 32), (uint32) lsn),
> > errdetail("running xacts with xcnt == 0")));
>
> It means there a xl_running_xacts record was encountered that had xcnt =
> 0 - allowing logical decoding to find a consistent start point
>
> > (or downgrade to debug message, if appropriate)?
>
> The message generally is quite relevant, as the process of finding a
> consistent start point can take quite a while. we don't really have a
> nice way to make errdetail() only be logged on a certain severity level
> as far as I am aware off.

Can we do just the errmsg() and remove with the errdetail?

> So maybe 'Encountered xl_running_xacts record with xcnt = 0.'?

That's not very user-facing, is it -- I mean, why bother the user with
the names of structs and members thereof? It seems better to describe
what the condition is; something like "found point in time with no
running transaction". Maybe "point in time" should be "WAL record"
instead.

--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2014-11-12 14:56:45 Re: Race condition between hot standby and restoring a FPW
Previous Message Andres Freund 2014-11-12 14:09:32 Re: what does this mean: "running xacts with xcnt == 0"