[ https://issues.apache.org/jira/browse/HIVE-25722?focusedWorklogId=687897&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-687897 ]
ASF GitHub Bot logged work on HIVE-25722: ----------------------------------------- Author: ASF GitHub Bot Created on: 30/Nov/21 09:53 Start Date: 30/Nov/21 09:53 Worklog Time Spent: 10m Work Description: pvary commented on a change in pull request #2799: URL: https://github.com/apache/hive/pull/2799#discussion_r759107544 ########## File path: itests/hive-unit/src/test/java/org/apache/hadoop/hive/ql/txn/compactor/TestCompactor.java ########## @@ -2314,6 +2315,10 @@ public void testCompactionOnDataLoadedInPath() throws Exception { executeStatementOnDriver("load data inpath '" + path002.toString() + "' into table comp3", driver); executeStatementOnDriver("load data inpath '" + path002.getParent().toString() + "' into table comp3", driver); + Table table3 = hmsClient.getTable("default", "comp3"); + Path delta2bucket0 = fs.globStatus(new Path(table3.getSd().getLocation(), "delta_0000002_0000002_0000/000000_0"))[0].getPath(); + Path emptyBucket = new Path(delta2bucket0.toString().replace("000000_0", "000003_0")); + fs.create(emptyBucket, true); Review comment: Who would create an empty file in an ACID table? It is a very important precondition that nobody should mess around the files under an ACID table directory. -- 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-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 687897) Time Spent: 20m (was: 10m) > Compaction fails if there are empty buckets. > -------------------------------------------- > > Key: HIVE-25722 > URL: https://issues.apache.org/jira/browse/HIVE-25722 > Project: Hive > Issue Type: Bug > Reporter: Arko Sharma > Assignee: Arko Sharma > Priority: Major > Labels: pull-request-available > Time Spent: 20m > Remaining Estimate: 0h > > Compaction fails if there are empty buckets. > This patch detects and deletes empty buckets before launching compaction in > order to protect it from failing. > Error stacktrace : > {code:java} > Caused by: java.lang.IllegalStateException: No 'original' files found for > bucketId=3 in > file:/Users/asharma/hive-fork/hive/itests/hive-unit/target/tmp/org.apache.hadoop.hive.ql.txn.compactor.TestCompactor-1638241161113_-1801963913/warehouse/comp3/delta_0000002_0000002_0000 > at > org.apache.hadoop.hive.ql.io.orc.OrcRawRecordMerger$OriginalReaderPairToCompact.<init>(OrcRawRecordMerger.java:602) > ~[hive-exec-4.0.0-SNAPSHOT.jar:4.0.0-SNAPSHOT] > at > org.apache.hadoop.hive.ql.io.orc.OrcRawRecordMerger.<init>(OrcRawRecordMerger.java:1154) > ~[hive-exec-4.0.0-SNAPSHOT.jar:4.0.0-SNAPSHOT] > at > org.apache.hadoop.hive.ql.io.orc.OrcInputFormat.getRawReader(OrcInputFormat.java:2462) > ~[hive-exec-4.0.0-SNAPSHOT.jar:4.0.0-SNAPSHOT] > at > org.apache.hadoop.hive.ql.txn.compactor.CompactorMR$CompactorMap.map(CompactorMR.java:811) > ~[hive-exec-4.0.0-SNAPSHOT.jar:?] > at > org.apache.hadoop.hive.ql.txn.compactor.CompactorMR$CompactorMap.map(CompactorMR.java:787) > ~[hive-exec-4.0.0-SNAPSHOT.jar:?] > at org.apache.hadoop.mapred.MapRunner.run(MapRunner.java:54) > ~[hadoop-mapreduce-client-core-3.1.0.jar:?] > at org.apache.hadoop.mapred.MapTask.runOldMapper(MapTask.java:465) > ~[hadoop-mapreduce-client-core-3.1.0.jar:?] > {code} -- This message was sent by Atlassian Jira (v8.20.1#820001)