wurstmeister / kafka-docker

Dockerfile for Apache Kafka
http://wurstmeister.github.io/kafka-docker/
Apache License 2.0
6.89k stars 2.73k forks source link

Kafka: CoordinatorNotAvailableError when consumers connects with group_id #701

Open DimaKalbfleysh opened 2 years ago

DimaKalbfleysh commented 2 years ago

I have kafka running in swarm mode. I have 1 broker with id "1", created a topic "my-topic:3:1".

When connecting consumers with group_id, the client gives the following error.

CoordinatorNotAvailableError

if group_id is not specified, then it connects successfully.

if created a topic with 1 partition, and connecting consumers with group_id, then it connects successfully.

Why consumers not connect with group_id when multiple partitions?

dvdblk commented 1 year ago

Getting something similar here. However, I'm creating three topics:

topic1:1:1 topic2:1:1 topic3:1:1

Each topic has its own group_id because I need multiple consumers per topic. When I start Zookeeper + Kafka for the first time I receive CoordinatorNotAvailableError. As soon as I restart it, everything works properly.

How can I make it work immediately without restarting?