mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 04:06:03 +00:00
no watch endpointslice in userpace mode
This commit is contained in:
parent
edc7f023a4
commit
c842cc5247
@ -364,6 +364,12 @@ func newProxyServer(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
useEndpointSlices := utilfeature.DefaultFeatureGate.Enabled(features.EndpointSliceProxying)
|
||||||
|
if proxyMode == proxyModeUserspace {
|
||||||
|
// userspace mode doesn't support endpointslice.
|
||||||
|
useEndpointSlices = false
|
||||||
|
}
|
||||||
|
|
||||||
return &ProxyServer{
|
return &ProxyServer{
|
||||||
Client: client,
|
Client: client,
|
||||||
EventClient: eventClient,
|
EventClient: eventClient,
|
||||||
@ -384,7 +390,7 @@ func newProxyServer(
|
|||||||
OOMScoreAdj: config.OOMScoreAdj,
|
OOMScoreAdj: config.OOMScoreAdj,
|
||||||
ConfigSyncPeriod: config.ConfigSyncPeriod.Duration,
|
ConfigSyncPeriod: config.ConfigSyncPeriod.Duration,
|
||||||
HealthzServer: healthzServer,
|
HealthzServer: healthzServer,
|
||||||
UseEndpointSlices: utilfeature.DefaultFeatureGate.Enabled(features.EndpointSliceProxying),
|
UseEndpointSlices: useEndpointSlices,
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -160,7 +160,11 @@ func newProxyServer(config *proxyconfigapi.KubeProxyConfiguration, cleanupAndExi
|
|||||||
return nil, fmt.Errorf("unable to create proxier: %v", err)
|
return nil, fmt.Errorf("unable to create proxier: %v", err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
useEndpointSlices := utilfeature.DefaultFeatureGate.Enabled(features.WindowsEndpointSliceProxying)
|
||||||
|
if proxyMode == proxyModeUserspace {
|
||||||
|
// userspace mode doesn't support endpointslice.
|
||||||
|
useEndpointSlices = false
|
||||||
|
}
|
||||||
return &ProxyServer{
|
return &ProxyServer{
|
||||||
Client: client,
|
Client: client,
|
||||||
EventClient: eventClient,
|
EventClient: eventClient,
|
||||||
@ -175,7 +179,7 @@ func newProxyServer(config *proxyconfigapi.KubeProxyConfiguration, cleanupAndExi
|
|||||||
OOMScoreAdj: config.OOMScoreAdj,
|
OOMScoreAdj: config.OOMScoreAdj,
|
||||||
ConfigSyncPeriod: config.ConfigSyncPeriod.Duration,
|
ConfigSyncPeriod: config.ConfigSyncPeriod.Duration,
|
||||||
HealthzServer: healthzServer,
|
HealthzServer: healthzServer,
|
||||||
UseEndpointSlices: utilfeature.DefaultFeatureGate.Enabled(features.WindowsEndpointSliceProxying),
|
UseEndpointSlices: useEndpointSlices,
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user