...
- (internal: removed) org.apache.kafka.streams.processor.internals.metrics.CumulativeCount
- (new) org.apache.kafka.common.metrics.stats.CumulativeCountTotalCount
non-sampled sum metric:
- (deprecated) org.apache.kafka.common.metrics.stats.Total
- (new) org.apache.kafka.common.metrics.stats.CumulativeSumTotalSum
Proposed Changes
The existing metrics cover four quadrants of a matrix:
count | sum | |
---|---|---|
sampled | Count | SampledTotal Sum |
non-sampled | (internal) CumulativeCount | Total |
It's immediately apparent that there's no consistency in naming, that there's a missing quadrant, and that one quadrant is redundantly covered.
The proposal is simple:
count | sum | |
---|---|---|
sampled | SampledCount | SampledSum |
non-sampled |
TotalCount |
TotalSum |
Under this proposal, the metrics are clearly and regularly named and all quadrants are covered uniquely. There is no ambiguity in the names, and the structure of the names also indicate a pattern that would guide users to select the correct metric for their needs.
...
Existing metrics are deprecated in favor of unambigously unambiguously named ones. They will be made to subclass the new metrics to avoid code duplication, but this won't cause any code compatibility issues, since they'll still inherit the same interfaces.
...