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

Allow domain sockets to configure SO_SNDBUF and SO_RCVBUF #9584

Merged
merged 3 commits into from
Sep 20, 2019

Conversation

ellisjoe
Copy link
Contributor

Motivation:

Running tests with a KQueueDomainSocketChannel showed worse performance than an NioSocketChannel. It turns out that the default send buffer size for Nio sockets is 64k while for KQueue sockets it's 8k. I verified that manually setting the socket's send buffer size improved perf to expected levels.

Modification:

Plumb the SO_SNDBUF and SO_RCVBUF options into the DomainSocketChannelConfig.

Result:

Can now configure send and receive buffer sizes for domain sockets.

@netty-bot
Copy link

Can one of the admins verify this patch?

Copy link
Member

@normanmaurer normanmaurer left a comment

Choose a reason for hiding this comment

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

Please also sign our icla: https://netty.io/s/icla

@ellisjoe
Copy link
Contributor Author

ellisjoe commented Sep 20, 2019

Thanks for the review @normanmaurer. I signed the icla and addressed your comments. Let me know if there's anything else you'd like me to follow up with.

@normanmaurer
Copy link
Member

normanmaurer commented Sep 20, 2019 via email

@normanmaurer
Copy link
Member

@netty-bot test this please

@normanmaurer normanmaurer merged commit aebe206 into netty:4.1 Sep 20, 2019
@normanmaurer
Copy link
Member

@ellisjoe thanks a lot!

normanmaurer pushed a commit that referenced this pull request Sep 20, 2019
Motivation:

Running tests with a `KQueueDomainSocketChannel` showed worse performance than an `NioSocketChannel`. It turns out that the default send buffer size for Nio sockets is 64k while for KQueue sockets it's 8k. I verified that manually setting the socket's send buffer size improved perf to expected levels.

Modification:

Plumb the `SO_SNDBUF` and `SO_RCVBUF` options into the `*DomainSocketChannelConfig`.

Result:

Can now configure send and receive buffer sizes for domain sockets.
@ellisjoe ellisjoe deleted the jellis/domainSocketBufferConf branch September 20, 2019 20:34
@normanmaurer normanmaurer added this to the 4.1.42.Final milestone Sep 25, 2019
@normanmaurer
Copy link
Member

@ellisjoe followup is here #9602

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.

None yet

3 participants