Repository: hive
Updated Branches:
  refs/heads/master 7584b3276 -> 04f5c6020


HIVE-19423 : REPL LOAD creates staging directory in source dump directory 
instead of table data location

Signed-off-by: Sankar Hariappan <sank...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/04f5c602
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/04f5c602
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/04f5c602

Branch: refs/heads/master
Commit: 04f5c6020f06669447047e076813ea90ba4e4371
Parents: 7584b32
Author: Mahesh Kumar Behera <mbeh...@hortonworks.com>
Authored: Fri May 4 23:52:47 2018 +0530
Committer: Sankar Hariappan <sank...@apache.org>
Committed: Mon May 7 22:43:36 2018 +0530

----------------------------------------------------------------------
 .../hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java   | 2 +-
 .../org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hive/blob/04f5c602/ql/src/java/org/apache/hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java
----------------------------------------------------------------------
diff --git 
a/ql/src/java/org/apache/hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java
 
b/ql/src/java/org/apache/hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java
index e2ec4af..d10ca76 100644
--- 
a/ql/src/java/org/apache/hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java
+++ 
b/ql/src/java/org/apache/hadoop/hive/ql/exec/repl/bootstrap/load/table/LoadTable.java
@@ -182,7 +182,7 @@ public class LoadTable {
         tracker.addTask(alterTableTask);
       } else {
         Task<?> loadTableTask =
-            loadTableTask(table, replicationSpec, event.metadataPath(), 
event.metadataPath());
+            loadTableTask(table, replicationSpec, table.getDataLocation(), 
event.metadataPath());
         alterTableTask.addDependentTask(loadTableTask);
         tracker.addTask(alterTableTask);
       }

http://git-wip-us.apache.org/repos/asf/hive/blob/04f5c602/ql/src/java/org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java
----------------------------------------------------------------------
diff --git 
a/ql/src/java/org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java 
b/ql/src/java/org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java
index fa32807..e6a7012 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/ImportSemanticAnalyzer.java
@@ -1079,7 +1079,7 @@ public class ImportSemanticAnalyzer extends 
BaseSemanticAnalyzer {
         x.getLOG().debug("table non-partitioned");
         if (!replicationSpec.isMetadataOnly()) {
           // repl-imports are replace-into unless the event is insert-into
-          loadTable(fromURI, table, replicationSpec.isReplace(), new 
Path(fromURI),
+          loadTable(fromURI, table, replicationSpec.isReplace(), 
table.getDataLocation(),
             replicationSpec, x, writeId, stmtId, isSourceMm);
         } else {
           x.getTasks().add(alterTableTask(tblDesc, x, replicationSpec));

Reply via email to