Skip to content

Improve send latency with TCP_NODELAY #783

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

Merged
merged 1 commit into from
Aug 1, 2016
Merged

Improve send latency with TCP_NODELAY #783

merged 1 commit into from
Aug 1, 2016

Conversation

dpkp
Copy link
Owner

@dpkp dpkp commented Jul 31, 2016

Fixes #717

This PR enables TCP_DELAY by default to reduce send latency (possibly at the expense of throughput). To allow more general socket tuning, I've also added a configuration parameter socket_options which will be passed directly to setsockopt() on each broker connection.

@dpkp dpkp merged commit 4162989 into master Aug 1, 2016
wmfgerrit pushed a commit to wikimedia/eventlogging that referenced this pull request Aug 2, 2016
…reader to test

dpkp/kafka-python#783 fixes a performance degradation
specifically related to synchronous producing, so this comit will
work best with kafka-python 1.2.6 or greater.

This also DRYs the logic for getting kafka client and group ids,
and adds an Event.serialize method to DRY up converting
events to JSON utf-8 strings.

Note that consumer balancing with kafka-python requires Kafka 0.9+

Bug: T133779
Change-Id: I3df00e9219f0a80c0805edd1df01c12fe8697341
@dpkp dpkp deleted the socket_options branch January 17, 2017 17:54
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.

1 participant