You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@hive.apache.org by GitBox <gi...@apache.org> on 2022/01/26 09:23:58 UTC

[GitHub] [hive] deniskuzZ commented on a change in pull request #2968: HIVE-25777: ACID: Pick the compactor transaction over insert dir

deniskuzZ commented on a change in pull request #2968:
URL: https://github.com/apache/hive/pull/2968#discussion_r792445062



##########
File path: ql/src/java/org/apache/hadoop/hive/ql/io/AcidUtils.java
##########
@@ -1812,7 +1812,12 @@ private static void processBaseDir(Path baseDir, ValidWriteIdList writeIdList, V
       directory.getAbortedWriteIds().add(parsedBase.writeId);
       return;
     }
-    if (directory.getBase() == null || directory.getBase().getWriteId() < writeId) {
+    if (directory.getBase() == null || directory.getBase().getWriteId() < writeId
+      // If there are two competing versions of a particular write-id, one from the compactor and another from IOW, 
+      // always pick the compactor one once it is committed.
+      || directory.getBase().getWriteId() == writeId && parsedBase.getVisibilityTxnId() > 0 

Review comment:
       fixed




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org