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 cn...@apache.org on 2025/01/23 19:36:01 UTC
(hadoop) branch branch-3.4 updated: HDFS-17711: Change fsimage loading progress percentage discontinuous to continuous
This is an automated email from the ASF dual-hosted git repository.
cnauroth pushed a commit to branch branch-3.4
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/branch-3.4 by this push:
new e5ce6c04596 HDFS-17711: Change fsimage loading progress percentage discontinuous to continuous
e5ce6c04596 is described below
commit e5ce6c045960fe238ffc1539df1c09da58450e36
Author: Sung Dong Kim <67...@users.noreply.github.com>
AuthorDate: Fri Jan 24 04:00:37 2025 +0900
HDFS-17711: Change fsimage loading progress percentage discontinuous to continuous
Co-authored-by: Sungdong Kim <ca...@kakaocorp.com>
Signed-off-by: Chris Nauroth <cn...@apache.org>
(cherry picked from commit 7ce4ea57807caac26342372f7a1cc2ef6f3b45a0)
---
.../org/apache/hadoop/hdfs/server/namenode/FSImageFormatPBINode.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/FSImageFormatPBINode.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImageFormatPBINode.java
index 1f21871ac7b..2199976931d 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImageFormatPBINode.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSImageFormatPBINode.java
@@ -423,6 +423,7 @@ void loadINodeSectionInParallel(ExecutorService service,
CountDownLatch latch = new CountDownLatch(sections.size());
AtomicInteger totalLoaded = new AtomicInteger(0);
final List<IOException> exceptions = Collections.synchronizedList(new ArrayList<>());
+ Counter counter = prog.getCounter(Phase.LOADING_FSIMAGE, currentStep);
for (int i=0; i < sections.size(); i++) {
FileSummary.Section s = sections.get(i);
@@ -433,9 +434,7 @@ void loadINodeSectionInParallel(ExecutorService service,
}
service.submit(() -> {
try {
- totalLoaded.addAndGet(loadINodesInSection(ins, null));
- prog.setCount(Phase.LOADING_FSIMAGE, currentStep,
- totalLoaded.get());
+ totalLoaded.addAndGet(loadINodesInSection(ins, counter));
} catch (Exception e) {
LOG.error("An exception occurred loading INodes in parallel", e);
exceptions.add(new IOException(e));
---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org