You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by pv...@apache.org on 2019/04/03 08:07:21 UTC
[hive] branch master updated: HIVE-21558: Query based compaction
fails if the temporary FS is different than the table FS (Peter Vary
reviewed Marta Kuczora)
This is an automated email from the ASF dual-hosted git repository.
pvary pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hive.git
The following commit(s) were added to refs/heads/master by this push:
new 8eefac7 HIVE-21558: Query based compaction fails if the temporary FS is different than the table FS (Peter Vary reviewed Marta Kuczora)
8eefac7 is described below
commit 8eefac7e8f7875bbf58fe7500ce17bea541891d0
Author: Peter Vary <pv...@cloudera.com>
AuthorDate: Wed Apr 3 10:06:05 2019 +0200
HIVE-21558: Query based compaction fails if the temporary FS is different than the table FS (Peter Vary reviewed Marta Kuczora)
---
.../java/org/apache/hadoop/hive/ql/txn/compactor/CompactorMR.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/CompactorMR.java b/ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/CompactorMR.java
index ac80bd1..e5f3047 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/CompactorMR.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/CompactorMR.java
@@ -547,8 +547,8 @@ public class CompactorMR {
* {@link org.apache.hadoop.hive.ql.exec.tez.SplitGrouper#getCompactorSplitGroups(InputSplit[], Configuration)},
* we will end up with one file per bucket.
*/
- private void commitCrudMajorCompaction(Table t, String from, String tmpTableName, String to, Configuration conf,
- ValidWriteIdList actualWriteIds, long compactorTxnId) throws IOException {
+ private void commitCrudMajorCompaction(Table t, String from, String tmpTableName, String to, HiveConf conf,
+ ValidWriteIdList actualWriteIds, long compactorTxnId) throws IOException, HiveException {
Path fromPath = new Path(from);
Path toPath = new Path(to);
Path tmpTablePath = new Path(fromPath, tmpTableName);
@@ -580,7 +580,7 @@ public class CompactorMR {
options = new AcidOutputFormat.Options(conf).writingBase(true).isCompressed(false).maximumWriteId(maxTxn)
.bucket(bucketId).statementId(-1).visibilityTxnId(compactorTxnId);
Path finalBucketFile = AcidUtils.createFilename(toPath, options);
- fs.rename(filestatus.getPath(), finalBucketFile);
+ Hive.moveFile(conf, filestatus.getPath(), finalBucketFile, true, false, false);
}
}
fs.delete(fromPath, true);