Documentation ¶
Index ¶
- func CreateNode(nodeID, ip string) client.HostNode
- type NodeManager
- func (n *NodeManager) AddAPIManager(apim *api.Manager) error
- func (n *NodeManager) CheckNodeHealthy() (bool, error)
- func (n *NodeManager) GetCurrentNode() *client.HostNode
- func (n *NodeManager) GetMonitorManager() monitor.Manager
- func (n *NodeManager) InitStart() error
- func (n *NodeManager) Start(errchan chan error) error
- func (n *NodeManager) StartService(serviceName string) error
- func (n *NodeManager) Stop()
- func (n *NodeManager) StopService(serviceName string) error
- func (n *NodeManager) UpdateConfig() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type NodeManager ¶
type NodeManager struct {
// contains filtered or unexported fields
}
NodeManager node manager
func NewNodeManager ¶
func NewNodeManager(conf *option.Conf) (*NodeManager, error)
NewNodeManager new a node manager
func (*NodeManager) AddAPIManager ¶
func (n *NodeManager) AddAPIManager(apim *api.Manager) error
AddAPIManager AddApiManager
func (*NodeManager) CheckNodeHealthy ¶
func (n *NodeManager) CheckNodeHealthy() (bool, error)
CheckNodeHealthy check current node healthy. only healthy can controller other service start
func (*NodeManager) GetCurrentNode ¶
func (n *NodeManager) GetCurrentNode() *client.HostNode
GetCurrentNode get current node
func (*NodeManager) GetMonitorManager ¶
func (n *NodeManager) GetMonitorManager() monitor.Manager
GetMonitorManager get monitor manager
func (*NodeManager) InitStart ¶
func (n *NodeManager) InitStart() error
InitStart init start is first start module. it would not depend etcd
func (*NodeManager) StartService ¶
func (n *NodeManager) StartService(serviceName string) error
StartService start a define service
func (*NodeManager) StopService ¶
func (n *NodeManager) StopService(serviceName string) error
StopService stop a define service
func (*NodeManager) UpdateConfig ¶
func (n *NodeManager) UpdateConfig() error
UpdateConfig update service config
Click to show internal directories.
Click to hide internal directories.