public LegacyStatCounter register(MeterRegistry registry) {
      Counter underlyingCounter = builder.register(registry);
      return new LegacyStatCounter(underlyingCounter, statisticBinding);
    }
Registers a {@code Counter} with the given registry, and returns a {@code LegacyStatCounter}
that wraps the counter to increment and read the associated stat. Note that the returned
{@code LegacyStatCounter} is not registered with the registry, but it has the same ID, so
it can be used to remove the registered counter from the registry.
geode-core/src/main/java/org/apache/geode/internal/statistics/meters/LegacyStatCounter.java