code: protected long getRecord(String record, IStatistic stats) {
      if (record == null || stats == null) {
        return 0;
      }
      IStatisticRecord statsRecord = stats.getRecordByName(record);
      if (statsRecord == null) {
        if (logger.isDebugEnabled()) {
          logger.debug("Warning: no record for {}, available: {}", record, Arrays.toString(stats.getRecords()));
        }
        return 0;
      }
      return statsRecord.getValueAsLong();
    }
docs: Return statistics record value from given {@link IStatistic}
  
  @param record key to retrieve
  @param stats  statistic object
  @return