Skip site navigation (1) Skip section navigation (2)

pgsql: Fix corner case in cleanup of transactions using SSI.

From: Heikki Linnakangas <heikki(dot)linnakangas(at)iki(dot)fi>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix corner case in cleanup of transactions using SSI.
Date: 2012-01-18 16:01:53
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-committers
Fix corner case in cleanup of transactions using SSI.

When the only remaining active transactions are READ ONLY, we do a "partial
cleanup" of committed transactions because certain types of conflicts
aren't possible anymore. For committed r/w transactions, we release the
SIREAD locks but keep the SERIALIZABLEXACT. However, for committed r/o
transactions, we can go further and release the SERIALIZABLEXACT too. The
problem was with the latter case: we were returning the SERIALIZABLEXACT to
the free list without removing it from the finished list.

The only real change in the patch is the SHMQueueDelete line, but I also
reworked some of the surrounding code to make it obvious that r/o and r/w
transactions are handled differently -- the existing code felt a bit too

Dan Ports



Modified Files
src/backend/storage/lmgr/predicate.c |   26 +++++++++++++++++++++++---
1 files changed, 23 insertions(+), 3 deletions(-)

pgsql-committers by date

Next:From: Peter EisentrautDate: 2012-01-18 19:03:24
Subject: pgsql: PL/Python: Update example
Previous:From: Magnus HaganderDate: 2012-01-18 09:35:40
Subject: pgsql: Show psql timing output for failed queries as well assuccessful

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group