Re: synchronized snapshots

From: Marko Tiikkaja <marko(dot)tiikkaja(at)2ndquadrant(dot)com>
To: Joachim Wieland <joe(at)mcknight(dot)de>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: synchronized snapshots
Date: 2011-09-28 06:29:08
Message-ID: 4E82BEB4.3070100@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Joachim,

On 14/09/2011 05:37, Joachim Wieland wrote:
> Here is a new version of this patch

In a sequence such as this:

BEGIN TRANSACTION ISOLATION LEVEL SERIALIZABLE;
INSERT INTO foo VALUES (-1);
SELECT pg_export_snapshot();

the row added to "foo" is not visible in the exported snapshot. If
that's the desired behaviour, I think it should be mentioned in the
documentation.

I can make a patched backend die with an assertion failure by trying to
export a snapshot after rolling back a transaction which exported a
snapshot. Seems like no cleanup is done at transaction abort.

I think that trying to import a snapshot that doesn't exist deserves a
better error message. There's currently no way for the user to know
that the snapshot didn't exist, other than looking at the SQLSTATE
(22023), and even that doesn't tell me a whole lot without looking at
the manual.

Finally, the comment in ImportSnapshot() still mentions the old syntax.

Other than these four problems, the patch looks good.

--
Marko Tiikkaja http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jaime Casanova 2011-09-28 06:38:47 Re: Updated version of pg_receivexlog
Previous Message Michael Paquier 2011-09-28 04:21:13 pg_regress input/output directory option