Back to

Package cluster

Latest Go to latest

The latest major version is .

Published: Apr 16, 2020 | License: LGPL-3.0 | Module:


type IPManager

type IPManager interface {
	//Whether the IP address belongs to the current node
	IPInCurrentHost(net.IP) bool
	Start() error
	//An IP pool change triggers a forced update of the gateway policy
	NeedUpdateGatewayPolicy() <-chan util.IPEVENT

IPManager ip manager Gets all available IP addresses for synchronizing the current node

func CreateIPManager

func CreateIPManager(ctx context.Context, config option.Config, etcdcli *clientv3.Client) (IPManager, error)

CreateIPManager create ip manage

type NodeManager

type NodeManager struct {
	// contains filtered or unexported fields

NodeManager node manager

func CreateNodeManager

func CreateNodeManager(ctx context.Context, config option.Config, etcdcli *clientv3.Client) (*NodeManager, error)

CreateNodeManager create node manager

func (*NodeManager) CheckPortAvailable

func (n *NodeManager) CheckPortAvailable(protocol string, ports ...uint32) bool

CheckPortAvailable checks whether the specified port is available

func (*NodeManager) IPManager

func (n *NodeManager) IPManager() IPManager

IPManager ip manager

func (*NodeManager) Start

func (n *NodeManager) Start() error

Start -

func (*NodeManager) Stop

func (n *NodeManager) Stop()

Stop -

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier