Making a txn commit/abort idempotent