0

we are using springboot application to develop kafka streams application. Till these days we are using single broker only so we are not facing any issues

But a week ago we created cluster mode with 3 zookeepers and 3 kafka broker for higher availability

we configured our application like the following.

spring.kafka.bootstrap-servers=x.x.x.x:9093,x.x.x.x:9093,x.x.x.x:9093

leader-1 leader-2 leader-3

So we are testing the server down behaviour below are the results

Expected behavior: it has to continuously run without any struggle by consuming and producing the data

Actual behavior: if we down any one server it will throw the exception and broker not available after some time application got stopped

while analysing the cause we found consuming topic is having leader-1 and data producing topic is having leader-2 so when i stop the leader-1 what we thought is it will change to the next leader but it is not?

is this is the default behaviour or else we are doing anything wrong?

can anyone please suggest me how to overcome this issue?

RandomUser
  • 31
  • 1
  • 8
  • Have you configured the replicas on the topics? You will get that error if there is only one replica and the node that hosts it goes down. – Gary Russell Apr 26 '21 at 13:29
  • Yes @GaryRussell ,we have configured the replicas as total broker count(3) and i check in all the broker dataLogs folder in ec2 instances every broker holding the topic folder – RandomUser Apr 28 '21 at 03:42
  • What about the consumer offsets topic? – OneCricketeer May 01 '21 at 07:49

0 Answers0