Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buffer batch for async producers #262

Merged
merged 2 commits into from
Jan 8, 2016
Merged

Conversation

carlessistare
Copy link
Collaborator

Other kafka connectors such as the Java one have the possibility to configurate an optional batch (client-side) for async producer mode, in order to send batches of messages instead of single messages at time. This increases performance because the kafka server doesnt need to answer ACK at every message.

The options are:

  • Batch size in bytes
  • Batch age in miliseconds

This will resolve #214

@carlessistare carlessistare force-pushed the batch-async branch 2 times, most recently from 9ebbb42 to 7d4ada2 Compare October 25, 2015 21:03
Other kafka connectors such as the Java one have the possibility to configurate an optional batch (client-side) for async producer mode, in order to send batches of messages instead of single messages at time. This increases performance because the kafka server doesnt need to answer ACK at every message.

The options are:
- Batch size in bytes
- Batch age in miliseconds
@mazerte
Copy link

mazerte commented Nov 2, 2015

+1

@haio
Copy link
Member

haio commented Nov 4, 2015

@carlessistare could you also update the document for this change.

@carlessistare
Copy link
Collaborator Author

Sorry @haio I'm not sure of which document you want me to update, could you precise? I'll do it with pleasure though

@carlessistare
Copy link
Collaborator Author

@haio I just added some doc on README.md file
c981598

* `connectionString`: Zookeeper connection string, default `localhost:2181/`
* `clientId`: This is a user-supplied identifier for the client application, default `kafka-node-client`
* `zkOptions`: **Object**, Zookeeper options, see [node-zookeeper-client](https://github.com/alexguan/node-zookeeper-client#client-createclientconnectionstring-options)
* `noAckBatchOptions`: **Object**, when requireAcks is disabled on Producer side we can define the batch properties, 'noAckBatchSize' in bytes and 'noAckBatchAge' in miliseconds. The default value is `{ noAckBatchSize: 500, noAckBatchAge: 300 }`
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: in milliseconds

haio added a commit that referenced this pull request Jan 8, 2016
Buffer batch for async producers
@haio haio merged commit 4d51e95 into SOHU-Co:master Jan 8, 2016
@OndroNR OndroNR mentioned this pull request Jan 8, 2016
@carlessistare carlessistare deleted the batch-async branch April 26, 2016 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Batch producer with transformed streams
4 participants