aeron-samples/src/main/java/io/aeron/samples/SamplesUtil.java
public static FragmentHandler rateReporterHandler(final RateReporter reporter)
    {
        return (buffer, offset, length, header) -> reporter.onMessage(1, length);
    }
public static FragmentHandler rateReporterHandler(final RateReporter reporter)
    {
        return (buffer, offset, length, header) -> reporter.onMessage(1, length);
    }
Return a reusable, parametrised {@link FragmentHandler} that calls into a
{@link RateReporter}.

@param reporter for the rate
@return {@link FragmentHandler} that records the rate information