Hi Colin and Kevin,

On Mon, Apr 14, 2025 at 5:25 PM Colin McCabe <cmcc...@apache.org> wrote:
> How about something like this?
>   10 = fenced
>   20 = controlled shutdown
>   30 = active

Very few users are going to know what these values mean. For example,
I see myself having to look up the code and KIP to remember these
values when monitoring clusters.

Did you consider making the metric a string? Most monitoring systems
implement "group by" and count aggregation so users would be able to
count how many brokers are fenced if they need to count them.

In the raft module we have a similar state metric. Check out the
current-state metric in KIP-595. The implementation of that metric is
in KafkaRaftMetrics#initialize.

Thanks,
-- 
-José

Reply via email to