public static BundleDistribution bundleProcessingThreadDistribution(
      String shortId, MetricName name) {
    return new BundleProcessingThreadDistribution(shortId, name);
  }
@Test
  public void testAccurateBundleDistributionUsingMultipleThreads() throws Exception {
    BundleDistribution bundleDistribution =
        Metrics.bundleProcessingThreadDistribution(TEST_ID, TEST_NAME);
    List<ByteString> values =
        testAccurateBundleMetricUsingMultipleThreads(
            bundleDistribution, () -> bundleDistribution.update(1));

    assertTrue(values.size() >= 10);
    List<DistributionData> sortedValues = new ArrayList<>();
    for (ByteString value : values) {
      sortedValues.add(MonitoringInfoEncodings.decodeInt64Distribution(value));
    }
    Collections.sort(sortedValues, Comparator.comparingLong(DistributionData::count));
    List<ByteString> sortedEncodedValues = new ArrayList<>();
    for (DistributionData value : sortedValues) {
      sortedEncodedValues.add(MonitoringInfoEncodings.encodeInt64Distribution(value));
    }
    assertThat(values, contains(sortedEncodedValues.toArray()));
  }