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

bugfix: do not merge catch-all canary backends with itself #3417

Merged
merged 1 commit into from Nov 20, 2018

Conversation

clandry94
Copy link
Contributor

@clandry94 clandry94 commented Nov 13, 2018

don't merge yet, I plan on adding a test for this case

What this PR does / why we need it:
If a canary backend is created at the catch all level of the ingress spec, it can merge with itself in some situations. If this happens, then the real backend won't know it exists.

This fixes the problem by iterating over each location at defServerName and merges with the first backend which has a server rather than the backend at location 0.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Nov 13, 2018
@clandry94
Copy link
Contributor Author

/assign @aledbf

@ElvinEfendi
Copy link
Member

@clandry94 can you add a regression test?

@aledbf aledbf added this to In Progress in 0.21.0 Nov 15, 2018
@aledbf
Copy link
Member

aledbf commented Nov 17, 2018

@clandry94 friendly ping

@clandry94
Copy link
Contributor Author

clandry94 commented Nov 17, 2018

Sorry for the delay. I’ll be picking back up on this this week.

@ElvinEfendi
Copy link
Member

/lgtm
/approve

This seems safe to merge, though it would still be nice to have a regression test. Merging so that we can release it as part of 0.21.0

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Nov 20, 2018
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: clandry94, ElvinEfendi

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 20, 2018
@k8s-ci-robot k8s-ci-robot merged commit 96f5ae6 into kubernetes:master Nov 20, 2018
@ElvinEfendi ElvinEfendi deleted the fix_canary_merge_self_def branch November 20, 2018 13:04
@aledbf aledbf moved this from In Progress to done in 0.21.0 Nov 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
No open projects
0.21.0
  
done
Development

Successfully merging this pull request may close these issues.

None yet

4 participants