Skip to content

Commit

Permalink
incorrect default
Browse files Browse the repository at this point in the history
Signed-off-by: Edoardo Vacchi <[email protected]>
  • Loading branch information
evacchi committed Jun 7, 2024
1 parent 9f49761 commit 0bd31a7
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -641,35 +641,70 @@ xds:
'@type': type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment
clusterName: httproute/default/backend/rule/0
endpoints:
- loadBalancingWeight: 1
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: 1.1.1.1
portValue: 8000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality:
region: httproute/default/backend/rule/0/backend/0
- endpointConfig:
'@type': type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment
clusterName: grpcroute/default/backend/rule/0
endpoints:
- loadBalancingWeight: 1
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: 1.1.1.1
portValue: 9000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality:
region: grpcroute/default/backend/rule/0/backend/0
- endpointConfig:
'@type': type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment
clusterName: tcproute/default/backend/rule/-1
endpoints:
- loadBalancingWeight: 1
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: 127.0.0.1
portValue: 3000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality:
region: tcproute/default/backend/rule/-1/backend/0
- endpointConfig:
'@type': type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment
clusterName: tlsroute/default/backend/rule/-1
endpoints:
- loadBalancingWeight: 1
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: 127.0.0.1
portValue: 3000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality:
region: tlsroute/default/backend/rule/-1/backend/0
- endpointConfig:
'@type': type.googleapis.com/envoy.config.endpoint.v3.ClusterLoadAssignment
clusterName: udproute/default/backend/rule/-1
endpoints:
- loadBalancingWeight: 1
- lbEndpoints:
- endpoint:
address:
socketAddress:
address: 127.0.0.1
portValue: 3000
loadBalancingWeight: 1
loadBalancingWeight: 1
locality:
region: udproute/default/backend/rule/-1/backend/0
- '@type': type.googleapis.com/envoy.admin.v3.ClustersConfigDump
Expand Down Expand Up @@ -1045,11 +1080,13 @@ xds:
- www.example.com
name: default/eg/http/www_example_com
routes:
- directResponse:
status: 500
match:
- match:
prefix: /
name: httproute/default/backend/rule/0/match/0/www_example_com
route:
cluster: httproute/default/backend/rule/0
upgradeConfigs:
- upgradeType: websocket
- routeConfig:
'@type': type.googleapis.com/envoy.config.route.v3.RouteConfiguration
ignorePortInHostMatching: true
Expand All @@ -1059,8 +1096,8 @@ xds:
- www.grpc-example.com
name: default/eg/grpc/www_grpc-example_com
routes:
- directResponse:
status: 500
match:
- match:
path: /com.example.Things/DoThing
name: grpcroute/default/backend/rule/0/match/0/www_grpc-example_com
route:
cluster: grpcroute/default/backend/rule/0
2 changes: 1 addition & 1 deletion internal/cmd/egctl/translate.go
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ func translateGatewayAPIToXds(dnsDomain string, resourceType string, resources *
func isEndpointRoutingDisabled(resources *gatewayapi.Resources) bool {
endpointRoutingDisabled := true
if resources.EnvoyProxy != nil {
switch ptr.Deref(resources.EnvoyProxy.Spec.RoutingType, egv1a1.EndpointRoutingType) {
switch ptr.Deref(resources.EnvoyProxy.Spec.RoutingType, egv1a1.ServiceRoutingType) {
case egv1a1.ServiceRoutingType:
// endPointRoutingDisable is already true.
default:
Expand Down

0 comments on commit 0bd31a7

Please sign in to comment.