Skip to content

Commit

Permalink
Adjust producer linger/batch configs
Browse files Browse the repository at this point in the history
  • Loading branch information
bryanlb committed Dec 19, 2023
1 parent 9a40bb2 commit 883c1e1
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -258,8 +258,9 @@ private KafkaProducer<String, byte[]> createKafkaTransactionProducer(String tran
props.put("key.serializer", "org.apache.kafka.common.serialization.StringSerializer");
props.put("value.serializer", "org.apache.kafka.common.serialization.ByteArraySerializer");
props.put("transactional.id", transactionId);
props.put("linger.ms", 250);
props.put("max.block.ms", "10000");
props.put("linger.ms", 500);
props.put("batch.size", 128000);
props.put("max.block.ms", 10000);
props.put("compression.type", "snappy");
return new KafkaProducer<>(props);
}
Expand Down

0 comments on commit 883c1e1

Please sign in to comment.