MCPcopy
hub / github.com/grpc/grpc-go / DefaultCluster

Function DefaultCluster

internal/testutils/xds/e2e/clientresources.go:445–452  ·  view source on GitHub ↗

DefaultCluster returns a basic xds Cluster resource.

(clusterName, edsServiceName string, secLevel SecurityLevel)

Source from the content-addressed store, hash-verified

443
444// DefaultCluster returns a basic xds Cluster resource.
445func DefaultCluster(clusterName, edsServiceName string, secLevel SecurityLevel) *v3clusterpb.Cluster {
446 return ClusterResourceWithOptions(ClusterOptions{
447 ClusterName: clusterName,
448 ServiceName: edsServiceName,
449 Policy: LoadBalancingPolicyRoundRobin,
450 SecurityLevel: secLevel,
451 })
452}
453
454// LoadBalancingPolicy determines the policy used for balancing load across
455// endpoints in the Cluster.

Calls 1