Skip to content

Commit

Permalink
Revert "Avoid adding original_dst filter when not needed (#10302)"
Browse files Browse the repository at this point in the history
This reverts commit 19334e8.
  • Loading branch information
freddygv authored Jun 2, 2021
1 parent 071007e commit ba4db7f
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 11 deletions.
4 changes: 0 additions & 4 deletions .changelog/10302.txt

This file was deleted.

13 changes: 6 additions & 7 deletions agent/xds/listeners.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,12 @@ func (s *ResourceGenerator) listenersFromSnapshotConnectProxy(cfgSnap *proxycfg.

outboundListener = makePortListener(OutboundListenerName, "127.0.0.1", port, envoy_core_v3.TrafficDirection_OUTBOUND)
outboundListener.FilterChains = make([]*envoy_listener_v3.FilterChain, 0)
outboundListener.ListenerFilters = []*envoy_listener_v3.ListenerFilter{
{
// TODO (freddy): Hard-coded until we upgrade the go-control-plane library
Name: "envoy.filters.listener.original_dst",
},
}
}

var hasFilterChains bool
Expand Down Expand Up @@ -201,13 +207,6 @@ func (s *ResourceGenerator) listenersFromSnapshotConnectProxy(cfgSnap *proxycfg.
if cfgSnap.ConnectProxy.MeshConfig == nil ||
!cfgSnap.ConnectProxy.MeshConfig.TransparentProxy.CatalogDestinationsOnly {

outboundListener.ListenerFilters = []*envoy_listener_v3.ListenerFilter{
{
// TODO (freddy): Hard-coded until we upgrade the go-control-plane library
Name: "envoy.filters.listener.original_dst",
},
}

filterChain, err := s.makeUpstreamFilterChainForDiscoveryChain(
"passthrough",
OriginalDestinationClusterName,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@
]
}
],
"listenerFilters": [
{
"name": "envoy.filters.listener.original_dst"
}
],
"trafficDirection": "OUTBOUND"
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@
]
}
],
"listenerFilters": [
{
"name": "envoy.filters.listener.original_dst"
}
],
"trafficDirection": "OUTBOUND"
},
{
Expand Down

0 comments on commit ba4db7f

Please sign in to comment.