Correctly detect SSI conflicts of prepared transactions after crash.

Heikki Linnakangas <heikki.linnakangas@iki.fi>

Commit: 86073a2b7acc58fce8701a9207a46adb41fbd8cc
Author: Heikki Linnakangas <heikki.linnakangas@iki.fi>
Date: 2012-02-29T13:43:43Z
Releases: 9.1.4
Correctly detect SSI conflicts of prepared transactions after crash.

A prepared transaction can get new conflicts in and out after preparing, so
we cannot rely on the in- and out-flags stored in the statefile at prepare-
time. As a quick fix, make the conservative assumption that after a restart,
all prepared transactions are considered to have both in- and out-conflicts.
That can lead to unnecessary rollbacks after a crash, but that shouldn't be
a big problem in practice; you don't want prepared transactions to hang
around for a long time anyway.

Dan Ports

Files

PathChange+/−
src/backend/storage/lmgr/predicate.c modified +15 −16