apiserver aggregator upgrade unit test
Co-authored-by: Chao Xu <xuchao@google.com> Kubernetes-commit: 0dfe8e33143aceacb2b47d66a967cc5e9cbeb94f
This commit is contained in:
parent
a00f1af772
commit
b57385a406
|
@ -362,6 +362,16 @@ func NewEgressSelector(config *apiserver.EgressSelectorConfiguration) (*EgressSe
|
|||
return cs, nil
|
||||
}
|
||||
|
||||
// NewEgressSelectorWithMap returns a EgressSelector with the supplied EgressType to DialFunc map.
|
||||
func NewEgressSelectorWithMap(m map[EgressType]utilnet.DialFunc) *EgressSelector {
|
||||
if m == nil {
|
||||
m = make(map[EgressType]utilnet.DialFunc)
|
||||
}
|
||||
return &EgressSelector{
|
||||
egressToDialer: m,
|
||||
}
|
||||
}
|
||||
|
||||
// Lookup gets the dialer function for the network context.
|
||||
// This is configured for the Kubernetes API Server at startup.
|
||||
func (cs *EgressSelector) Lookup(networkContext NetworkContext) (utilnet.DialFunc, error) {
|
||||
|
|
Loading…
Reference in New Issue