schema-registry-statistics
schema-registry-statistics copied to clipboard
Support random value for `--group` property and make it default
Is your proposal related to a problem?
It is always some additional effort to specify a new Consumer Group ID when you re-run the utility against the same broker and the same topic. For this, one should specify some new unique value for the --group
command property.
Describe the solution you'd like
Add support for --group random
and make this default.
When specified like this (and also by default), use schema-registry-stats-<unique number or string>
as the group ID.
This will allow to re-run the tool against the same topic as many times as needed to re-consume all records from it from the beginning. There is one pitfall of this approach - when access control in the company is so strict, that only particular group IDs are allowed, then a random group ID could not be used. However, for such environments it would be probably easier to specify a specific group ID instead of a random one (also see alternatives below).
Describe alternatives you've considered
Alternatively, a --reset-offsets
(or similar) configuration property could be helpful to instruct the tool to use the earliest offset from the topic.
Not quite clear what exactly the --oldest
configuration property does, but it looks like it is respected only on the first run for a specific group ID. Probably should be somehow reconciled with --reset-offsets
or similar.
Additional context
schema-registry-statistics version: 1.2.0