a. Sync producer b. request.required.acks = -1 c. compression.codec="gzip" with send(List<KeyedMessage>)
I'm not quite sure what you meant by 2, but committed all or nothing can somewhat be achieved by placing all messages in a batch in one compressed message. So I suggested c) above. Thanks, Neha On Fri, Feb 28, 2014 at 3:20 PM, Sudarshan Kadambi (BLOOMBERG/ 731 LEXIN) < skada...@bloomberg.net> wrote: > Hi: > > If someone's intention is to implement a producer such that: > 1. The call to send() blocks until the write is successful on the > configured number or replicas or max num of retries. > 2. The call to send() takes in a configurable batch of messages that is > committed all or nothing. > > what combination of the following should they choose? > a. Sync vs. Async producer > b. request.required.acks = 0, 1 or -1 > c. send(KeyedMessage) vs. send(List<KeyedMessage>) > > There is information on all of the above, but I wanted to hear this > explicitly from someone more experienced that I am at Kafka.