final RegionMetrics buildRegionMetrics(final TableName tableName) throws Exception {
    final List<Method> setters = new ArrayList<>(regionMetricsBuilderLongValueSetters);
    Collections.shuffle(setters, rand);

    final RegionInfo regionInfo = RegionInfoBuilder.newBuilder(tableName).build();
    final RegionMetricsBuilder builder =
      RegionMetricsBuilder.newBuilder(regionInfo.getRegionName());
    for (final Method setter : setters.subList(0, 3)) {
      setter.invoke(builder, rand.nextLong());
    }
    return builder.build();
  }
Build a {@link RegionMetrics} object for {@code tableName}. Populates a couple random fields
with non-empty values.
hbase-server/src/test/java/org/apache/hadoop/hbase/master/http/TestRegionVisualizer.java