"YAMAMOTO Takashi" wrote: > Description: SetRWConflict assertion failure > SerializableXactHashLock relocking in CheckTargetForConflictsIn() > seems racy to me. You're right. The attached patch should fix the assertion you hit. I will take a close look at the code above the patched area (for the optimization to drop the predicate lock when we acquire a write lock). Looking at it just now I'm wondering if it really is a safe optimization in PostgreSQL. It was in the Cahill paper, but InnoDB doesn't have subtransactions. I fear that we could give up the SIReadLock within a subtransaction and then have problems if the subtransaction rolls back, effectively discarding the write lock. I suspect we need to do this only if we're not within a subtransaction. Will follow up on that after further review. Thanks! -Kevin
ssi-recheck-conflict-in-before-flagging.patch
Description: Binary data
-- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs