Re: Master-slave visibility order

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Ants Aasma <ants(at)cybertec(dot)at>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Master-slave visibility order
Date: 2013-08-29 21:59:25
Message-ID: 9541.1377813565@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> But I think that actually coordinating a consistent visibility order
> between commit, wal insertion and the procarray would have bigger
> scalability impact than the second record. I might be missing some
> clever tricks here though.

Yeah. ISTM the only way to really guarantee that the visible commit
order is the same would be for transactions to hold the ProcArrayLock
while they're inserting that WAL record. Needless to say, that would
be absolutely disastrous performance-wise.

Or at least, that's true as long as we rely on the current procarray-based
mechanism for noting that a transaction is still in progress. Maybe
there's some other approach altogether.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2013-08-29 22:04:08 Re: PL/pgSQL PERFORM with CTE
Previous Message Andres Freund 2013-08-29 21:59:12 Re: PL/pgSQL PERFORM with CTE