I'm using Kafka in a system where data safety should be at its notch. To set up a Kafka topic I need to guarantee that no message will be lost. What I found is,
- if I use acks=1, we can't guarantee that messages will not be lost, - if I use acks= all, I will have a good data safety but unclean leader failover may lead to data loss. As I found setting acks=all and *unclean.leader.election.enable = false *will give us data safety so that no message will be lost (sacrificing the availability of the system). Is this the best option I have if I need zero message loss with maximum availability? Can anyone clarify? Thanks.