Browse Source

HADOOP-2481. NNBench report its progress periodically.
(Hairong Kuang via dhruba)



git-svn-id: https://svn.apache.org/repos/asf/lucene/hadoop/trunk@611958 13f79535-47bb-0310-9956-ffa450edef68

Dhruba Borthakur 17 years ago
parent
commit
ea9482c3b0
2 changed files with 11 additions and 0 deletions
  1. 3 0
      CHANGES.txt
  2. 8 0
      src/test/org/apache/hadoop/dfs/NNBench.java

+ 3 - 0
CHANGES.txt

@@ -442,6 +442,9 @@ Trunk (unreleased changes)
 
     HADOOP-2571. Suppress a suprious warning in test code. (cdouglas)
 
+    HADOOP-2481. NNBench report its progress periodically.
+    (Hairong Kuang via dhruba)
+
 Release 0.15.3 - (unreleased changes)
 
   BUG FIXES

+ 8 - 0
src/test/org/apache/hadoop/dfs/NNBench.java

@@ -770,6 +770,8 @@ public class NNBench {
             totalTimeAL2 += (System.currentTimeMillis() - startTimeAL);
             successfulOp = true;
             successfulFileOps ++;
+
+            reporter.setStatus("Finish "+ l + " files");
           } catch (IOException e) {
             TaskTracker.LOG.info("Exception recorded in op: " +
                     "Create/Write/Close");
@@ -811,6 +813,8 @@ public class NNBench {
             input.close();
             successfulOp = true;
             successfulFileOps ++;
+
+            reporter.setStatus("Finish "+ l + " files");
           } catch (IOException e) {
             TaskTracker.LOG.info("Exception recorded in op: OpenRead " + e);
             numOfExceptions++;
@@ -841,6 +845,8 @@ public class NNBench {
             
             successfulOp = true;
             successfulFileOps ++;
+
+            reporter.setStatus("Finish "+ l + " files");
           } catch (IOException e) {
             TaskTracker.LOG.info("Exception recorded in op: Rename");
 
@@ -870,6 +876,8 @@ public class NNBench {
             
             successfulOp = true;
             successfulFileOps ++;
+
+            reporter.setStatus("Finish "+ l + " files");
           } catch (IOException e) {
             TaskTracker.LOG.info("Exception in recorded op: Delete");