You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by mi...@apache.org on 2017/10/10 15:13:37 UTC
[5/5] incubator-impala git commit: IMPALA-6016: Fix logging in
TableLoadingMgr class
IMPALA-6016: Fix logging in TableLoadingMgr class
This patch moves the logging of "loads in progress"
to a place where the current load is accounted. The
reason to move the logging is that the current load
is not reflected in the loadingTables_ till loadAsync()
is called.
Change-Id: I925a6ba9a09be25df2759da5e6d85dfc8b981ce4
Reviewed-on: http://gerrit.cloudera.org:8080/8212
Reviewed-by: Bharath Vissapragada <bh...@cloudera.com>
Tested-by: Impala Public Jenkins
Project: http://git-wip-us.apache.org/repos/asf/incubator-impala/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-impala/commit/c189d0a3
Tree: http://git-wip-us.apache.org/repos/asf/incubator-impala/tree/c189d0a3
Diff: http://git-wip-us.apache.org/repos/asf/incubator-impala/diff/c189d0a3
Branch: refs/heads/master
Commit: c189d0a39cfb106f369522c57926196cc772da5e
Parents: e570343
Author: Bharath Vissapragada <bh...@cloudera.com>
Authored: Wed Oct 4 15:30:03 2017 -0700
Committer: Impala Public Jenkins <im...@gerrit.cloudera.org>
Committed: Tue Oct 10 02:45:46 2017 +0000
----------------------------------------------------------------------
.../java/org/apache/impala/catalog/TableLoadingMgr.java | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-impala/blob/c189d0a3/fe/src/main/java/org/apache/impala/catalog/TableLoadingMgr.java
----------------------------------------------------------------------
diff --git a/fe/src/main/java/org/apache/impala/catalog/TableLoadingMgr.java b/fe/src/main/java/org/apache/impala/catalog/TableLoadingMgr.java
index f3abfee..d07c0ed 100644
--- a/fe/src/main/java/org/apache/impala/catalog/TableLoadingMgr.java
+++ b/fe/src/main/java/org/apache/impala/catalog/TableLoadingMgr.java
@@ -67,6 +67,10 @@ public class TableLoadingMgr {
public Table get() {
Table tbl;
try {
+ LOG.info("Loading metadata for table: " +
+ tblName_.db_name + "." + tblName_.table_name);
+ LOG.info(String.format("Remaining items in queue: %s. Loads in progress: %s",
+ tableLoadingDeque_.size(), loadingTables_.size()));
tbl = tblTask_.get();
} catch (Exception e) {
tbl = IncompleteTable.createFailedMetadataLoadTable(
@@ -282,15 +286,12 @@ public class TableLoadingMgr {
private void loadNextTable() throws InterruptedException {
// Always get the next table from the head of the deque.
final TTableName tblName = tableLoadingDeque_.takeFirst();
- LOG.info("Loading next table from queue: " +
- tblName.db_name + "." + tblName.table_name);
- LOG.info(String.format("Remaining items in queue: %s. Loads in progress: %s",
- tableLoadingDeque_.size(), loadingTables_.size()));
-
AtomicBoolean isLoading = tableLoadingBarrier_.get(tblName);
if (isLoading == null || !isLoading.compareAndSet(false, true)) {
// Another thread has already completed the load or the load is still in progress.
// Return so this thread can work on another table in the queue.
+ LOG.info("Metadata load request already in progress for table: " +
+ tblName.db_name + "." + tblName.table_name);
return;
}
try {