-
Notifications
You must be signed in to change notification settings - Fork 3.4k
cilium: sock termination fixes #39800
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
Conversation
This is just forward-porting commit d3c80fa ("SocketLB: Terminate connections for services with mixed protocols") given it has been missing in the new control plane. Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
filterAndDestroyUDPSockets has family as an argument, but iterateNetlinkSockets kept hard-coding syscall.AF_INET as input. Pass the right family along instead of the latter. It seems this was an oversight from refactoring in commit c7760bd ("sockets: use general purpose iterateNetlinkSockets function.") Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
/test |
@@ -184,7 +184,7 @@ func terminateUDPConnectionsToBackend(p socketTerminationParams, l3n4Addr lb.L3n | |||
l4Addr := l3n4Addr.L4Addr | |||
|
|||
switch l3n4Addr.Protocol { | |||
case lb.UDP: | |||
case lb.UDP, lb.ANY: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lb.ANY
should be impossible with the new control-plane as at least currently you can't turn off "protocol differentiation". But good to add this still as we might still end up adding the ability to turn it off...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah ok, but what happens when people upgrade and they still have old ANY entries in the maps where then the backend goes away?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those are removed by the reconciler once the maps have been populated with the new entries.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those are removed by the reconciler once the maps have been populated with the new entries.
(see individual commit msgs)