Skip to content

xds/clusterresolver: implement gRFC A61 changes for LOGICAL_DNS clusters#8733

Merged
Pranjali-2501 merged 12 commits into
grpc:masterfrom
Pranjali-2501:a61
Feb 4, 2026
Merged

xds/clusterresolver: implement gRFC A61 changes for LOGICAL_DNS clusters#8733
Pranjali-2501 merged 12 commits into
grpc:masterfrom
Pranjali-2501:a61

Conversation

@Pranjali-2501

@Pranjali-2501 Pranjali-2501 commented Dec 1, 2025

Copy link
Copy Markdown
Contributor

Fixes : #8153

This PR implements the "Changes to Logical DNS Clusters" section of gRFC A61 (IPv4/IPv6 Dual-stack Backends).

Currently, LOGICAL_DNS clusters in the xDS cluster resolver have their Load Balancing policy hard-coded to pick_first. This ensures the semantics of connecting to only one address at a time.

This PR updates the xds_cluster_resolver logic. The buildClusterImplConfigForDNS function removes the hard-coded pick_first policy restriction for LOGICAL_DNS clusters, allowing them to use the configured LB policy.
Also, in the DNS update handler, all resolved addresses are now grouped into a single resolver.Endpoint. This ensures that regardless of the configured parent LB policy, the child policy sees a single "backend" endpoint containing all addresses.

RELEASE NOTES:

  • xds: LOGICAL_DNS clusters now honor the LB policy configured in the cluster resource, rather than defaulting to a hardcoded pick_first policy.

@Pranjali-2501 Pranjali-2501 added this to the 1.78 Release milestone Dec 1, 2025
@Pranjali-2501 Pranjali-2501 added Type: Feature New features or improvements in behavior Area: xDS Includes everything xDS related, including LB policies used with xDS. labels Dec 1, 2025
@codecov

codecov Bot commented Dec 1, 2025

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.35%. Comparing base (830c909) to head (41ff069).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8733      +/-   ##
==========================================
- Coverage   83.42%   83.35%   -0.07%     
==========================================
  Files         414      414              
  Lines       32751    32754       +3     
==========================================
- Hits        27322    27302      -20     
- Misses       4040     4057      +17     
- Partials     1389     1395       +6     
Files with missing lines Coverage Δ
...rnal/xds/balancer/clusterresolver/configbuilder.go 92.59% <100.00%> (+0.16%) ⬆️

... and 17 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread internal/xds/balancer/clusterresolver/resource_resolver_dns.go Outdated
Comment thread internal/xds/balancer/clusterresolver/resource_resolver_dns.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
@easwars

easwars commented Dec 1, 2025

Copy link
Copy Markdown
Contributor

This change probably needs a release note.

@easwars easwars assigned Pranjali-2501 and unassigned easwars and arjan-bal Dec 1, 2025
@Pranjali-2501 Pranjali-2501 requested a review from easwars December 3, 2025 17:59
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder_test.go Outdated
Comment thread internal/xds/balancer/clusterresolver/e2e_test/dns_impl_test.go Outdated
Comment thread internal/xds/balancer/cdsbalancer/e2e_test/dns_impl_test.go
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder.go Outdated
Comment thread internal/xds/balancer/clusterresolver/configbuilder_test.go Outdated
@easwars easwars assigned Pranjali-2501 and unassigned easwars Jan 29, 2026
@Pranjali-2501 Pranjali-2501 merged commit 55bfbbb into grpc:master Feb 4, 2026
14 checks passed
mbissa pushed a commit to mbissa/grpc-go that referenced this pull request Feb 10, 2026
…ers (grpc#8733)

Fixes : grpc#8153 

This PR implements the "Changes to Logical DNS Clusters" section of
[gRFC A61 (IPv4/IPv6 Dual-stack
Backends)](https://github.com/grpc/proposal/blob/master/A61-IPv4-IPv6-dualstack-backends.md#changes-to-logical-dns-clusters).

Currently, `LOGICAL_DNS` clusters in the xDS cluster resolver have their
Load Balancing policy hard-coded to `pick_first`. This ensures the
semantics of connecting to only one address at a time.

This PR updates the `xds_cluster_resolver` logic. The
`buildClusterImplConfigForDNS` function removes the hard-coded
`pick_first` policy restriction for `LOGICAL_DNS` clusters, allowing
them to use the configured LB policy.
Also, in the DNS update handler, all resolved addresses are now grouped
into a single `resolver.Endpoint`. This ensures that regardless of the
configured parent LB policy, the child policy sees a single "backend"
endpoint containing all addresses.

RELEASE NOTES: 
* xds: `LOGICAL_DNS` clusters now honor the LB policy configured in the
cluster resource, rather than defaulting to a hardcoded `pick_first`
policy.
mbissa pushed a commit to mbissa/grpc-go that referenced this pull request Feb 16, 2026
…ers (grpc#8733)

Fixes : grpc#8153 

This PR implements the "Changes to Logical DNS Clusters" section of
[gRFC A61 (IPv4/IPv6 Dual-stack
Backends)](https://github.com/grpc/proposal/blob/master/A61-IPv4-IPv6-dualstack-backends.md#changes-to-logical-dns-clusters).

Currently, `LOGICAL_DNS` clusters in the xDS cluster resolver have their
Load Balancing policy hard-coded to `pick_first`. This ensures the
semantics of connecting to only one address at a time.

This PR updates the `xds_cluster_resolver` logic. The
`buildClusterImplConfigForDNS` function removes the hard-coded
`pick_first` policy restriction for `LOGICAL_DNS` clusters, allowing
them to use the configured LB policy.
Also, in the DNS update handler, all resolved addresses are now grouped
into a single `resolver.Endpoint`. This ensures that regardless of the
configured parent LB policy, the child policy sees a single "backend"
endpoint containing all addresses.

RELEASE NOTES: 
* xds: `LOGICAL_DNS` clusters now honor the LB policy configured in the
cluster resource, rather than defaulting to a hardcoded `pick_first`
policy.
This was referenced Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area: xDS Includes everything xDS related, including LB policies used with xDS. Type: Feature New features or improvements in behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Behavior change for A61 update: remove special case for LOGICAL_DNS clusters

5 participants