public void populate ( Result result ) { // process path-level stats and properties NavigableMap < byte [ ] , byte [ ] > infoValues = result . getFamilyMap ( HdfsConstants . DISK_INFO_FAM_BYTES ) ; this . fileCount += ByteUtil . getValueAsLong ( HdfsConstants . FILE_COUNT_COLUMN_BYTES , infoValues ) ; this . dirCount += ByteUtil . getValueAsLong ( HdfsConstants . DIR_COUNT_COLUMN_BYTES , infoValues ) ; this . spaceConsumed += ByteUtil . getValueAsLong ( HdfsConstants . SPACE_CONSUMED_COLUMN_BYTES , infoValues ) ; this . accessCountTotal += ByteUtil . getValueAsLong ( HdfsConstants . ACCESS_COUNT_TOTAL_COLUMN_BYTES , infoValues ) ; this . owner = ByteUtil . getValueAsString ( HdfsConstants . OWNER_COLUMN_BYTES , infoValues ) ; this . quota += ByteUtil . getValueAsLong ( HdfsConstants . QUOTA_COLUMN_BYTES , infoValues ) ; this . spaceQuota += ByteUtil . getValueAsLong ( HdfsConstants . SPACE_QUOTA_COLUMN_BYTES , infoValues ) ; this . tmpFileCount += ByteUtil . getValueAsLong ( HdfsConstants . TMP_FILE_COUNT_COLUMN_BYTES , infoValues ) ; this . tmpSpaceConsumed += ByteUtil . getValueAsLong ( HdfsConstants . TMP_SPACE_CONSUMED_COLUMN_BYTES , infoValues ) ; this . trashFileCount += ByteUtil . getValueAsLong ( HdfsConstants . TRASH_FILE_COUNT_COLUMN_BYTES , infoValues ) ; this . trashSpaceConsumed += ByteUtil . getValueAsLong ( HdfsConstants . TRASH_SPACE_CONSUMED_COLUMN_BYTES , infoValues ) ; this . accessCost += ByteUtil . getValueAsDouble ( HdfsConstants . ACCESS_COST_COLUMN_BYTES , infoValues ) ; this . storageCost += ByteUtil . getValueAsDouble ( HdfsConstants . STORAGE_COST_COLUMN_BYTES , infoValues ) ; this . hdfsCost = calculateHDFSCost ( ) ; }
populates the hdfs stats by looking through the hbase result