Fixed the behavior when the rest of the transaction needs to be delayed when one of its transactions is delayed. Also, now it really is a strict two-phase locking because it releases its locks after committing.