Package org.apache.hadoop.raid.RaidHistogram

Examples of org.apache.hadoop.raid.RaidHistogram.BlockFixStatus


  }
 
  public static String getRecoveryLag(long window,
      TreeMap<Long, BlockFixStatus> countersMap, String path,
      String infoAddr) throws UnsupportedEncodingException {
    BlockFixStatus bfs = countersMap.get(window);
    StringBuilder sb1 = new StringBuilder();
    for (int i = 0; i < bfs.percents.size(); i++) {
      if (i > 0) {
        sb1.append("/");
      }
View Full Code Here


  }
 
  public static String getFailedFiles(long window,
      TreeMap<Long, BlockFixStatus> countersMap, String path,
      String infoAddr) throws UnsupportedEncodingException {
    BlockFixStatus bfs = countersMap.get(window);
    String counterDisplay = "";
    if (bfs.failedPaths <= 0) {
      counterDisplay = "0";
    } else {
      StringBuffer url = new StringBuffer("http://" + infoAddr
View Full Code Here

  }
 
  public void printBlockFixStatus(TreeMap<Long, BlockFixStatus> status) {
    for (Long window: status.keySet()) {
      LOG.info("Window: " + window);
      BlockFixStatus bfs = status.get(window);
      LOG.info("failedPaths: " + bfs.failedPaths);
      String values = "";
      for (Long val: bfs.percentValues) {
        values += "/" + val;
      }
View Full Code Here

            cnode.blockIntegrityMonitor.getBlockFixStatus(
            monitorDir, nPercents, percents, sTime + gapTime - 1000);
        printBlockFixStatus(status);
        assertTrue(status.containsKey(windows.get(0)));
        assertTrue(status.containsKey(windows.get(1)));
        BlockFixStatus bfs = status.get(windows.get(0));
        // Verify failed recovered files for the first window
        assertEquals("The number of failed recovery files should match",
            sendRound*nPercents, bfs.failedPaths);
        // Verify percent values for the first window
        assertEquals(nPercents + 1, bfs.percentValues.length);
View Full Code Here

        TreeMap<Long, BlockFixStatus> status =
            cnode.blockIntegrityMonitor.getBlockFixStatus(
            monitorDir, nPercents, percents, endTime);
        assertTrue(status.containsKey(newWindows.get(0)));
         assertTrue(status.containsKey(newWindows.get(1)));
         BlockFixStatus bfs = status.get(newWindows.get(0));
        assertEquals("Stale entries are not filtered", rounds*nPercents*2*2,
            cnode.blockIntegrityMonitor.getNumberOfPoints(monitorDir));
        // Verify failed recovered files for the first window
        assertEquals("The number of failed recovery files should match",
            rounds*nPercents, bfs.failedPaths);
View Full Code Here

TOP

Related Classes of org.apache.hadoop.raid.RaidHistogram.BlockFixStatus

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.