Skip to content

Route53 weighted routing - #4843

Open
dominikhei wants to merge 2 commits into
kubernetes-sigs:mainfrom
dominikhei:route53-weighted-routing
Open

Route53 weighted routing#4843
dominikhei wants to merge 2 commits into
kubernetes-sigs:mainfrom
dominikhei:route53-weighted-routing

Conversation

@dominikhei

@dominikhei dominikhei commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Issue

#4747

Description

This PR adds support for Route53's Weighted routing policy for ACM DNS validation records, controlled by two new flags:

--route53-validation-record-routing-policy selects the routing policy (simple or weighted). simple preserves existing behavior exactly.
--route53-validation-record-weight the weight assigned to this controller's validation records. Only used when policy is weighted. Must be a positive integer (weight 0 would cause Route53 to never return the record, preventing ACM from completing validation).

When set to weighted, each controller creates its validation record using Route53's Weighted routing policy with --cluster-name as the SetIdentifier. This allows multiple controllers to each own a validation record for the same domain name without conflicting. Both flags are exposed as Helm values (route53ValidationRecordRoutingPolicy, route53ValidationRecordWeight) for users deploying via Helm.

I tested all changes end-to-end by creating two kubernetes clusters in EKS, each running its own AWS Load Balancer Controller deployment with --route53-validation-record-routing-policy=weighted and --cluster-name set to the respective cluster name. Both controllers were pointed at the same Route53 hosted zone and each processed an Ingress with create-acm-cert: "true" for the same hostname, triggering ACM certificate requests and DNS validation record creation. The Route53 output confirmed that both controllers successfully created coexisting weighted records for the same validation name.

With Simple routing policy this would fail, the second controller's ChangeResourceRecordSets call would be rejected because a record for that name already exists.

I additionally changed the following behavior:

The validation record create and delete paths now share a single buildValidationResourceRecordSet method to guarantee they stay in sync as Route53 requires a DELETE's ResourceRecordSet to exactly match what was originally created, including SetIdentifier and Weight for weighted records. I someone thinks this should not be the case, I am happy to roll this back :).

Checklist

  • Added tests that cover your change (if possible)
  • Added/modified documentation as required (such as the README.md, or the docs directory)
  • Manually tested
  • Made sure the title of the PR is a good description that can go into the release notes

BONUS POINTS checklist: complete for good vibes and maybe prizes?! 🤯

  • Backfilled missing tests for code in same general area 🎉
  • Refactored something and made the world a better place 🌟

@kubernetes-prow
kubernetes-prow Bot requested review from oliviassss and shuqz July 17, 2026 13:09
@kubernetes-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: dominikhei
Once this PR has been reviewed and has the lgtm label, please assign oliviassss for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details 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

@kubernetes-prow kubernetes-prow Bot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jul 17, 2026
@kubernetes-prow

Copy link
Copy Markdown
Contributor

Hi @dominikhei. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

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-sigs/prow repository.

@kubernetes-prow kubernetes-prow Bot added needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Jul 17, 2026
@dominikhei
dominikhei force-pushed the route53-weighted-routing branch from dcf85ce to 6fb1089 Compare July 23, 2026 14:27
@kubernetes-prow kubernetes-prow Bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant