Documentation ¶
Index ¶
- type NodeBase
- func (n *NodeBase) CreateAlertScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
- func (n *NodeBase) CreateFailedScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
- func (n *NodeBase) CreateFinishedScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
- func (n *NodeBase) CreateLogScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
- func (n *NodeBase) CreateOutputScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
- func (n *NodeBase) DoConfigure(configs ...mq.BrokerConfigHandler)
- func (n *NodeBase) GetRPCClient() *mq.RPCClient
- func (n *NodeBase) GetRPCServer() *mq.RPCServer
- func (n *NodeBase) GetRootContext() context.Context
- func (n *NodeBase) GetToken() string
- func (n *NodeBase) HookAfterRegisteringFinished(fs ...func())
- func (n *NodeBase) HookOnNotificationComingHandler(f ...func(msg *amqp.Delivery))
- func (n *NodeBase) IsRegistered() bool
- func (n *NodeBase) NewBaseMessage(typeInfo spec.MessageType) *spec.Message
- func (n *NodeBase) Notify(key string, msg *spec.Message)
- func (n *NodeBase) NotifyHeartbeat(key string, msg *spec.Message)
- func (n *NodeBase) RegisterTickerFunc(name string, intervalSec int, first bool, f func()) error
- func (n *NodeBase) Serve()
- func (n *NodeBase) Shutdown()
- func (n *NodeBase) UnregisterTickerFunc(name string)
- func (n *NodeBase) WalkTickerFunc(cb func(name string, f *tickerFunc))
- func (n *NodeBase) WithCancelContext() (context.Context, context.CancelFunc)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type NodeBase ¶
type NodeBase struct { NodeType spec.NodeType NodeId string WebServerPort string ExternalIp string // 脚本执行引擎 ScriptExecutor *yak.ScriptEngine // contains filtered or unexported fields }
func NewNodeBase ¶
func (*NodeBase) CreateAlertScriptRuntimeMessage ¶
func (n *NodeBase) CreateAlertScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
func (*NodeBase) CreateFailedScriptRuntimeMessage ¶
func (n *NodeBase) CreateFailedScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
func (*NodeBase) CreateFinishedScriptRuntimeMessage ¶
func (n *NodeBase) CreateFinishedScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
func (*NodeBase) CreateLogScriptRuntimeMessage ¶
func (n *NodeBase) CreateLogScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
func (*NodeBase) CreateOutputScriptRuntimeMessage ¶
func (n *NodeBase) CreateOutputScriptRuntimeMessage(taskId, msg string) *spec.ScriptRuntimeMessage
func (*NodeBase) DoConfigure ¶
func (n *NodeBase) DoConfigure(configs ...mq.BrokerConfigHandler)
func (*NodeBase) GetRPCClient ¶
func (*NodeBase) GetRPCServer ¶
func (*NodeBase) GetRootContext ¶
func (*NodeBase) HookAfterRegisteringFinished ¶
func (n *NodeBase) HookAfterRegisteringFinished(fs ...func())
func (*NodeBase) HookOnNotificationComingHandler ¶
func (*NodeBase) IsRegistered ¶
func (*NodeBase) NewBaseMessage ¶
func (n *NodeBase) NewBaseMessage(typeInfo spec.MessageType) *spec.Message
func (*NodeBase) NotifyHeartbeat ¶
func (*NodeBase) RegisterTickerFunc ¶
func (*NodeBase) UnregisterTickerFunc ¶
func (*NodeBase) WalkTickerFunc ¶
func (*NodeBase) WithCancelContext ¶
func (n *NodeBase) WithCancelContext() (context.Context, context.CancelFunc)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.