kafka-go
kafka-go copied to clipboard
added-autoderive-batchSize--added-check-after-compression
Hi guys.
We are using driver segmentio/kafka-go, and encountered several problems:
- User should set BatchBytes manually (when driver can just take 'max.message.bytes' from broker)
- WriteMessages can be used to write into multiple topics, each topic can have own 'max.message.bytes' limit - but BatchBytes is one for writer
- When messages exceed BatchBytes - it returns an error, but this check occurs before compression. Actually message can be compressed and successfully produced into kafka.
I couldn't solve it by wrapper over driver, and decided to expand a driver.
Here are my idea - to add two boolean options in driver, and turn-on new behaviour only when they set into 'true'. I know there should be tests to be considered for merging - but I don't know, maybe this my approach isn't canonical or something else may be wrong, and maybe I shouldn't waste time on tests, if PR anyway will be rejected.
So, what do you think?
Atlantis commands can't be run on fork pull requests. To enable, set --allow-fork-prs or, to disable this message, set --silence-fork-pr-errors
Error parsing command: EOF found when expecting closing quote
Atlantis commands can't be run on fork pull requests. To enable, set --allow-fork-prs or, to disable this message, set --silence-fork-pr-errors
Error parsing command: EOF found when expecting closing quote
Atlantis commands can't be run on fork pull requests. To enable, set --allow-fork-prs or, to disable this message, set --silence-fork-pr-errors
Error parsing command: EOF found when expecting closing quote