Kafka - All concepts and functionality explained through sample Java Codes
We can find sample Java code here for
- Demo Kafka Producer --> ProducerDemo.java
- Kafka Producer with CallBacks --> ProducerDemoWithCallback.java
- Kafka Producer with Keys --> ProducerDemoKeys.java
- At any time only 1 broker can be a leader for a partition and only that leader can receive and send the data for the partition.
- The Other broker will synchronize the data.
- Therefore each partition has 1 leader and multiple ISR(in-sync-replica)