Re: Serializable snapshot isolation error logging

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Dan S" <strd911(at)gmail(dot)com>,<pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Serializable snapshot isolation error logging
Date: 2010-09-20 18:20:24
Message-ID: 4C975F9802000025000359F6@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Dan S <strd911(at)gmail(dot)com> wrote:

> I wonder if the SSI implementation will give some way of detecting
> the cause of a serialization failure.
> Something like the deadlock detection maybe where you get the
> sql-statements involved.

I've been wondering what detail to try to include. There will often
be three transactions involved in an SSI serialization failure,
although the algorithm we're using (based on the referenced papers)
may only know about one or two of them at the point of failure,
because conflicts with multiple other transactions get collapsed to
a self-reference. (One "optimization" I want to try is to maintain
a list of conflicts rather than doing the above -- in which case we
could always show all three transactions; but we may run out of time
for that, and even if we don't, the decreased rollbacks might not
pay for the cost of maintaining such a list.)

The other information we would have would be the predicate locks
held by whatever transactions we know about at the point of
cancellation, based on what reads they've done; however, we wouldn't
know about the writes done by those transaction, or which of the
reads resulting in conflicts.

So, given the above, any thoughts on what we *should* show?

-Kevin

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-09-20 18:21:27 Re: Git conversion status
Previous Message Magnus Hagander 2010-09-20 18:19:05 Re: Git conversion status