Re: [PATCH] Transaction traceability - txid_status(bigint)

From: Craig Ringer <craig(at)2ndquadrant(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Petr Jelinek <petr(at)2ndquadrant(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Andres Freund <andres(at)anarazel(dot)de>, Jim Nasby <Jim(dot)Nasby(at)bluetreble(dot)com>, Álvaro Herrera <alvaro(dot)herrera(at)2ndquadrant(dot)com>
Subject: Re: [PATCH] Transaction traceability - txid_status(bigint)
Date: 2017-03-20 05:38:18
Views: Raw Message | Whole Thread | Download mbox
Lists: pgsql-hackers

On 14 March 2017 at 19:57, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> On Mon, Mar 13, 2017 at 10:22 PM, Craig Ringer <craig(at)2ndquadrant(dot)com> wrote:
>> I'll introduce a new LWLock, ClogTruncationLock, which will be held
>> from when we advance the new clogOldestXid field through to when clog
>> truncation completes.
> +1.

OK, here's the revised patch. Relevant comments added where needed.

It still changes the xlog record for clog truncation to carry the new
xid, but I've left advancing oldestXid until the checkpoint as is
currently the case, and only advanced oldestClogXid when we replay
clog truncation.

Craig Ringer
PostgreSQL Development, 24x7 Support, Training & Services

Attachment Content-Type Size
0001-Fix-race-between-clog-truncation-and-lookup.patch text/x-patch 13.3 KB
0002-Introduce-txid_status-bigint-to-get-status-of-an-xac.patch text/x-patch 12.6 KB

In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message David Rowley 2017-03-20 05:47:58 Re: Patch to improve performance of replay of AccessExclusiveLock
Previous Message Andres Freund 2017-03-20 04:16:21 Re: WIP: Faster Expression Processing v4