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 2020/02/27 13:03:22 UTC
[hive] branch master updated: HIVE-22819: Refactor
Hive::listFilesCreatedByQuery to make it faster for object stores (Marton
Bod reviewed by Steve Loughran and Peter Vary)
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 ff9fa68 HIVE-22819: Refactor Hive::listFilesCreatedByQuery to make it faster for object stores (Marton Bod reviewed by Steve Loughran and Peter Vary)
ff9fa68 is described below
commit ff9fa68ee26ae80986b264e7342b7347fc0b16a9
Author: Marton Bod <mb...@cloudera.com>
AuthorDate: Thu Feb 27 14:02:27 2020 +0100
HIVE-22819: Refactor Hive::listFilesCreatedByQuery to make it faster for object stores (Marton Bod reviewed by Steve Loughran and Peter Vary)
---
ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java b/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
index d40a67f..3b0b56d 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/metadata/Hive.java
@@ -2617,18 +2617,13 @@ public class Hive {
Path acidDir = new Path(loadPath, AcidUtils.baseOrDeltaSubdir(isInsertOverwrite, writeId, writeId, stmtId));
try {
FileSystem srcFs = loadPath.getFileSystem(conf);
- if (srcFs.exists(acidDir) && srcFs.isDirectory(acidDir)){
- // list out all the files in the path
- listFilesInsideAcidDirectory(acidDir, srcFs, newFiles);
- } else {
- LOG.info("directory does not exist: " + acidDir);
- return;
- }
+ listFilesInsideAcidDirectory(acidDir, srcFs, newFiles);
+ } catch (FileNotFoundException e) {
+ LOG.info("directory does not exist: " + acidDir);
} catch (IOException e) {
LOG.error("Error listing files", e);
throw new HiveException(e);
}
- return;
}
private void setStatsPropAndAlterPartition(boolean resetStatistics, Table tbl,