You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by su...@apache.org on 2019/10/14 18:10:19 UTC
[hadoop] branch trunk updated: HDFS-14886. In NameNode Web UI's
Startup Progress page,
Loading edits always shows 0 sec. Contributed by hemanthboyina.
This is an automated email from the ASF dual-hosted git repository.
surendralilhore pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/trunk by this push:
new 336abbd HDFS-14886. In NameNode Web UI's Startup Progress page, Loading edits always shows 0 sec. Contributed by hemanthboyina.
336abbd is described below
commit 336abbd8737f3dff38f7bdad9721511c711c522b
Author: Surendra Singh Lilhore <su...@apache.org>
AuthorDate: Mon Oct 14 23:31:43 2019 +0530
HDFS-14886. In NameNode Web UI's Startup Progress page, Loading edits always shows 0 sec. Contributed by hemanthboyina.
---
.../main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
index 5681807..9b95f14 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
@@ -757,8 +757,10 @@ public class FSImage implements Closeable {
prog.endPhase(Phase.LOADING_FSIMAGE);
if (!rollingRollback) {
+ prog.beginPhase(Phase.LOADING_EDITS);
long txnsAdvanced = loadEdits(editStreams, target, Long.MAX_VALUE,
startOpt, recovery);
+ prog.endPhase(Phase.LOADING_EDITS);
needToSave |= needsResaveBasedOnStaleCheckpoint(imageFile.getFile(),
txnsAdvanced);
} else {
@@ -890,8 +892,6 @@ public class FSImage implements Closeable {
StartupOption startOpt, MetaRecoveryContext recovery)
throws IOException {
LOG.debug("About to load edits:\n " + Joiner.on("\n ").join(editStreams));
- StartupProgress prog = NameNode.getStartupProgress();
- prog.beginPhase(Phase.LOADING_EDITS);
long prevLastAppliedTxId = lastAppliedTxId;
long remainingReadTxns = maxTxnsToRead;
@@ -930,7 +930,6 @@ public class FSImage implements Closeable {
} finally {
FSEditLog.closeAllStreams(editStreams);
}
- prog.endPhase(Phase.LOADING_EDITS);
return lastAppliedTxId - prevLastAppliedTxId;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org