code: private int populateHdfsStats(Result result,
        Map<HdfsStatsKey, HdfsStats> hdfsStats, boolean checkPath, String path,
        long starttime, long endtime, int rowCount) {
      HdfsStatsKey currentFullKey = hdfsStatsKeyConv.fromBytes(result.getRow());
      QualifiedPathKey qpk = currentFullKey.getQualifiedPathKey();
  
      // we check for exact match of path
      // since the scan does a prefix match, we need to filter out
      // other paths
      if (checkPath) {
        if (!qpk.getPath().equalsIgnoreCase(StringUtil.cleanseToken(path))) {
          return rowCount;
        }
        // sanity check
        if ((currentFullKey.getRunId() < endtime)
            || (currentFullKey.getRunId() > starttime)) {
          return rowCount;
        }
      }
      // create a hdfs stats key object per path without namespace
      // that will enable aggregating stats across all namespaces
      HdfsStatsKey currentKey = new HdfsStatsKey(qpk.getCluster(), qpk.getPath(),
          currentFullKey.getEncodedRunId());
      HdfsStats currentHdfsStats = hdfsStats.get(currentKey);
      if (currentHdfsStats != null) {
        currentHdfsStats.populate(result);
      } else {
        currentHdfsStats = new HdfsStats(new HdfsStatsKey(currentKey));
        currentHdfsStats.populate(result);
        hdfsStats.put(currentKey, currentHdfsStats);
      }
      return rowCount + 1;
    }
docs: Populates the hdfs stats for a cluster based on the hbase Result
  
  For federated hadoop2 clusters, there are multiple namespaces Since the
  namespace is part of the rowkey, we need to create an hdfs key without
  namespace so that we can aggregate across namespaces
  
  @param hbase scan result
  @param map of hdfsStats