-
Notifications
You must be signed in to change notification settings - Fork 17
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
Poll netlink socket using Erlang port #1
base: master
Are you sure you want to change the base?
Conversation
Replace the now broken (after R15) use of gen_udp for socket notification with open_port/2.
Remove the use of inet:getfd/1. The file descriptor for a port can't be retrieved. The code is also simplified.
Call the terminate function on exit and close the netlink sockets.
Sorry for the late response, I simply didn't get the notification... One problem with the use of gen_udp was, that it could cause the kernel internal socket buffers to overflow. We have added some code recently to counter that. For the port approach, that raises the question if the port driver can drain the kernel input queue fast enough? I'll try to run this on our test bed where it will get some load to see if it can keep up. |
On Fri, Jun 15, 2012 at 01:30:41AM -0700, Andreas Schultz wrote:
Hey Andreas, no prob, thanks for considering this patch!
Really?! This is the OS buffers?
Curious to see the results too. The other problem is there is no flow
Sounds great! It's been a while since I looked at gen_netlink, but: the Not sure if that makes sense for you and I'm happy to keep a fork, just |
On Fri, Jun 15, 2012 at 2:21 PM, Michael Santos
Yes, the socket buffer to be precise. I have some code to resize the
We have worked on extending the gen_socket module with that. The idea
There is not much generic code in there, most of the stuff is concerned with
I was thinking about talking to OpenVSwitch for a while as well, but
|
Replace the now broken (after R15) use of gen_udp for socket notification
with open_port/2.
All the tests passed for me except test_rt_delroute/1 but that seems to be a problem with netlink:nl_rt_enc/1 rather than with the socket.