@@ -21,7 +21,6 @@ import (
2121
2222 xdsapi "github.com/envoyproxy/go-control-plane/envoy/api/v2"
2323 "github.com/envoyproxy/go-control-plane/envoy/api/v2/route"
24- "github.com/gogo/protobuf/types"
2524
2625 "istio.io/istio/pilot/pkg/model"
2726 istio_route "istio.io/istio/pilot/pkg/networking/core/v1alpha3/route"
@@ -73,20 +72,13 @@ func (configgen *ConfigGeneratorImpl) buildSidecarInboundHTTPRouteConfig(env *mo
7372 }
7473
7574 for _ , p := range configgen .Plugins {
76- var perRouteFilterConfig map [string ]* types.Struct
77- if c , ok := configgen .PerRouteFilterConfig [p .GetName ()].(map [string ]* types.Struct ); ok {
78- perRouteFilterConfig = c
79- } else {
80- perRouteFilterConfig = nil
81- }
8275 in := & plugin.InputParams {
83- ListenerProtocol : plugin .ListenerProtocolHTTP ,
84- Env : env ,
85- Node : node ,
86- ServiceInstance : instance ,
87- Service : instance .Service ,
88- Push : push ,
89- PerRouteFilterConfig : perRouteFilterConfig ,
76+ ListenerProtocol : plugin .ListenerProtocolHTTP ,
77+ Env : env ,
78+ Node : node ,
79+ ServiceInstance : instance ,
80+ Service : instance .Service ,
81+ Push : push ,
9082 }
9183 p .OnInboundRouteConfiguration (in , r )
9284 }
@@ -185,18 +177,11 @@ func (configgen *ConfigGeneratorImpl) buildSidecarOutboundHTTPRouteConfig(env *m
185177
186178 // call plugins
187179 for _ , p := range configgen .Plugins {
188- var perRouteFilterConfig map [string ]* types.Struct
189- if c , ok := configgen .PerRouteFilterConfig [p .GetName ()].(map [string ]* types.Struct ); ok {
190- perRouteFilterConfig = c
191- } else {
192- perRouteFilterConfig = nil
193- }
194180 in := & plugin.InputParams {
195- ListenerProtocol : plugin .ListenerProtocolHTTP ,
196- Env : env ,
197- Node : node ,
198- Push : push ,
199- PerRouteFilterConfig : perRouteFilterConfig ,
181+ ListenerProtocol : plugin .ListenerProtocolHTTP ,
182+ Env : env ,
183+ Node : node ,
184+ Push : push ,
200185 }
201186 p .OnOutboundRouteConfiguration (in , out )
202187 }
0 commit comments