Documentation ¶
Index ¶
- func NewEndpointFuncs(namePrefix, idFormat string, getPodCIDRs PodCIDRsGetter) (GetNameFunc, GetIDFunc, NewEndpointFunc)
- type AgentArgumentMap
- func (argMap AgentArgumentMap) ArgumentArray() []string
- func (argMap AgentArgumentMap) Delete(name string)
- func (argMap AgentArgumentMap) Get(name string) string
- func (argMap AgentArgumentMap) HasKey(name string) bool
- func (argMap AgentArgumentMap) IsDNSEnabled() bool
- func (argMap AgentArgumentMap) IsDNSProbeEnabled() bool
- func (argMap AgentArgumentMap) IsProxyEnabled() bool
- func (argMap AgentArgumentMap) Set(name, value string)
- type ClusterCIDRsMap
- type Community
- type EndpointGetter
- type GetClusterCIDRInfo
- type GetIDFunc
- type GetNameFunc
- type NewEndpointFunc
- type PodCIDRStore
- type PodCIDRsGetter
- type SafeStringSet
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewEndpointFuncs ¶
func NewEndpointFuncs(namePrefix, idFormat string, getPodCIDRs PodCIDRsGetter) (GetNameFunc, GetIDFunc, NewEndpointFunc)
Types ¶
type AgentArgumentMap ¶ added in v0.6.0
AgentArgumentMap is used to manage arguments of agent pod
func NewAgentArgumentMap ¶ added in v0.6.0
func NewAgentArgumentMap() AgentArgumentMap
func NewAgentArgumentMapFromEnv ¶ added in v0.6.0
func NewAgentArgumentMapFromEnv() AgentArgumentMap
NewAgentArgumentMapFromEnv extract arguments of agent pod from ENV, each agent argument should be configured like:
AGENT_ARG_ENABLE_IPAM=true
The return value is a map, each key is the ENV variable name but with prefix 'AGENT_ARG_' stripped and the key is also lowered.
func (AgentArgumentMap) ArgumentArray ¶ added in v0.6.0
func (argMap AgentArgumentMap) ArgumentArray() []string
ArgumentArray translate argument map into sorted argument array All arguments are sorted except log level, `agent` doesn't have an option named log-level, instead it has a 'v' option which is used to configure log level. ArgumentArray will put 'v' option at the end of argument array.
func (AgentArgumentMap) Delete ¶ added in v0.6.0
func (argMap AgentArgumentMap) Delete(name string)
func (AgentArgumentMap) Get ¶ added in v0.6.0
func (argMap AgentArgumentMap) Get(name string) string
func (AgentArgumentMap) HasKey ¶ added in v0.6.0
func (argMap AgentArgumentMap) HasKey(name string) bool
func (AgentArgumentMap) IsDNSEnabled ¶ added in v0.8.0
func (argMap AgentArgumentMap) IsDNSEnabled() bool
func (AgentArgumentMap) IsDNSProbeEnabled ¶ added in v0.8.0
func (argMap AgentArgumentMap) IsDNSProbeEnabled() bool
func (AgentArgumentMap) IsProxyEnabled ¶ added in v0.6.0
func (argMap AgentArgumentMap) IsProxyEnabled() bool
func (AgentArgumentMap) Set ¶ added in v0.6.0
func (argMap AgentArgumentMap) Set(name, value string)
type ClusterCIDRsMap ¶ added in v0.7.0
type ClusterCIDRsMap struct {
// contains filtered or unexported fields
}
func NewClusterCIDRsMap ¶ added in v0.7.0
func NewClusterCIDRsMap() *ClusterCIDRsMap
func (*ClusterCIDRsMap) Delete ¶ added in v0.7.0
func (m *ClusterCIDRsMap) Delete(name string)
func (*ClusterCIDRsMap) Get ¶ added in v0.7.0
func (m *ClusterCIDRsMap) Get(name string) ([]string, bool)
func (*ClusterCIDRsMap) GetCopy ¶ added in v0.7.0
func (m *ClusterCIDRsMap) GetCopy() map[string][]string
GetCopy return a copy of inner data, the returned data should not be changed
func (*ClusterCIDRsMap) Set ¶ added in v0.7.0
func (m *ClusterCIDRsMap) Set(name string, cidrs []string)
type EndpointGetter ¶
type GetClusterCIDRInfo ¶ added in v0.7.0
type GetNameFunc ¶
type PodCIDRStore ¶
type PodCIDRStore interface { Append(nodeName string, cidr ...string) Remove(nodeName string, cidr ...string) RemoveAll(nodeName string) RemoveByPodCIDR(podCIDR string) Get(nodeName string) []string GetNodeNameByPodCIDR(cidr string) (string, bool) }
func NewPodCIDRStore ¶
func NewPodCIDRStore() PodCIDRStore
type PodCIDRsGetter ¶
type SafeStringSet ¶
type SafeStringSet struct {
// contains filtered or unexported fields
}
func NewSafeStringSet ¶
func NewSafeStringSet(v ...string) *SafeStringSet
func (*SafeStringSet) Delete ¶ added in v0.5.0
func (s *SafeStringSet) Delete(value ...string)
func (*SafeStringSet) Equal ¶
func (s *SafeStringSet) Equal(o *SafeStringSet) bool
func (*SafeStringSet) Has ¶ added in v0.5.0
func (s *SafeStringSet) Has(v string) bool
func (*SafeStringSet) Insert ¶ added in v0.5.0
func (s *SafeStringSet) Insert(value ...string)
func (*SafeStringSet) Len ¶
func (s *SafeStringSet) Len() int
func (*SafeStringSet) List ¶ added in v0.5.0
func (s *SafeStringSet) List() []string