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

Setting the the size of the operating system's receive buffer #22

Closed
hasso opened this issue Aug 16, 2016 · 2 comments
Closed

Setting the the size of the operating system's receive buffer #22

hasso opened this issue Aug 16, 2016 · 2 comments

Comments

@hasso
Copy link

hasso commented Aug 16, 2016

Default size of the receive buffer OSes are assigning to connections isn't often big enough for receiving a lot of traffic and it needs to be adjusted. There isn't a way to do it at the moment from application using go-collectd and I have to patch go-collectd itself - it shouldn't be necessary.

@octo
Copy link
Member

octo commented Aug 21, 2016

Hi @hasso, thanks for reporting this.

I don't think proxying all sorts of UDP settings through the network API is the right way to go. What do you think about this approach:

  • Add Conn *net.UDPConn to the Server type.
  • If Conn == nil, use Addr to create a new *net.UDPConn with default settings.
  • Otherwise, use the user-provided Conn.

Best regards,
—octo

octo added a commit that referenced this issue Sep 5, 2016
This allows callers to set up a listen socket with more specific settings,
e.g. an enlarged receive buffer.

Issue: #22
@octo
Copy link
Member

octo commented Sep 5, 2016

That should fix this.. If this doesn't work for your case, let me know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants