-
Notifications
You must be signed in to change notification settings - Fork 303
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
Trigger updating DualStack ILB Service if ipFamilies changed #1928
Trigger updating DualStack ILB Service if ipFamilies changed #1928
Conversation
@panslava: GitHub didn't allow me to assign the following users: mmamczur. Note that only kubernetes members with read permissions, repo collaborators and people who have commented on this issue/PR can be assigned. Additionally, issues/PRs can only have 10 assignees at the same time. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
4909dfc
to
23cadfd
Compare
@@ -482,6 +482,11 @@ func (l4c *L4Controller) needsUpdate(oldService *v1.Service, newService *v1.Serv | |||
oldService.Spec.HealthCheckNodePort, newService.Spec.HealthCheckNodePort) | |||
return true | |||
} | |||
if l4c.enableDualStack && !reflect.DeepEqual(oldService.Spec.IPFamilies, newService.Spec.IPFamilies) { |
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.
or maybe comparing ClusterIPs ?
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.
I was considering it, but I think IPFamilies are better,
All the logic in sync depends on IPFamilies (to identify if service needs ipv4 or ipv6), and, we don't really need info about exactly clusterIPs changes (even though they should not change without ipFamilies..), we only need to know ipFamilies state
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.
do we care about ordering here?
if it changes from IPv4,IPv6 -> IPv6,IPv4 should this trigger an update?
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.
good point, just, by kubernetes design, first ipFamily should never change, because 1st ipFamily correlates with ClusterIP which is immutable (not ClusterIPs)
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.
but maybe I should not rely on kubernetes still?
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.
so it's super unlikely anyway because it would be rejected by the apiserver
I'd leave that since one extra 'update' won't hurt us
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.
Thanks! I think so too :)
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: aojea, panslava The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Currently, updating ipFamilies do not trigger L4 ILB service update. This is a bug fix
/assign cezarygerard
/assign mmamczur