IBM / sarama

Sarama is a Go library for Apache Kafka.
MIT License
11.59k stars 1.76k forks source link

Is it possible and how to run a preferred replica election with sarama? #2744

Open hjweddie opened 11 months ago

hjweddie commented 11 months ago

Description

I am developing kafka management tools with sarama, and I don't know that is it possible and how to run a preferred replica election with sarama?

Additional context

None

prestona commented 11 months ago

Hi @hjweddie - it looks like the elect leaders API is used to implement leader election in the Java client. Unfortunately this API is not currently implemented by Sarama. So to answer you question: no this is not currently possible with Sarama.

If you would like to contribute an implementation of the elect leaders API - I'm sure it would be gratefully received. 😄