diff --git metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java index 2aa5d20..ec03f76 100644 --- metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java +++ metastore/src/java/org/apache/hadoop/hive/metastore/ObjectStore.java @@ -463,14 +463,14 @@ public void rollbackTransaction() { debugLog("Rollback transaction, isActive: " + currentTransaction.isActive()); if (currentTransaction.isActive() && transactionStatus != TXN_STATUS.ROLLBACK) { - transactionStatus = TXN_STATUS.ROLLBACK; // could already be rolled back currentTransaction.rollback(); - // remove all detached objects from the cache, since the transaction is - // being rolled back they are no longer relevant, and this prevents them - // from reattaching in future transactions - pm.evictAll(); } + transactionStatus = TXN_STATUS.ROLLBACK; + // remove all detached objects from the cache, since the transaction is + // being rolled back they are no longer relevant, and this prevents them + // from reattaching in future transactions + pm.evictAll(); } @Override