Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is the leader part of ISR list

If i set the min.insync.replicas to 1, the leader will wait for a follower to fetch this record or he will send an ack to producer considering himself one of the ISR list.

like image 702
HISI Avatar asked Oct 19 '25 15:10

HISI


1 Answers

If you set min.insync.replicas to 1 it is sufficient that the leader will acknowledge the receival of data. The leader will not wait for any followers to acknowledge the data.

Maybe it is worth mentioning that the min.insync.replicas only comes into effect when you have set your producer configuration acks set to all (or -1).

The minimal allowed value for min.insync.replicas is 1, so even if your replication factor of the topic is set to 1 you can't get below 1.

Is the leader part of ISR list?

Yes, the leader is part of the ISR list. You can see this when calling the command line tool kafka-topics. In the result you will notice that the same broker number will show up as "Leader" and in "ISR":

./bin/kafka-topics.sh --bootstrap-server localhost:9092 --describe --topic test 
Topic: test PartitionCount: 1 ReplicationFactor: 3  
Topic: test Partition: 0 Leader: 3 Replicas: 2,3,1 Isr: 3
like image 170
Michael Heil Avatar answered Oct 21 '25 04:10

Michael Heil