Documentation ¶
Index ¶
- func Run(config *viper.Viper, s chan error) (err error)
- type Agent
- func (a *Agent) ControllerStart() error
- func (a *Agent) DispatchAgent(agentMsg *control.Agent) error
- func (a *Agent) DispatchSink(payload *rpc.Message, sinkName string)
- func (a *Agent) DispatchSource(payload *rpc.Message, sourceName string)
- func (a *Agent) GetConfig() error
- func (a *Agent) GetSchemas() *control.Agent
- func (a *Agent) GetSourceAvailableAction(sourceName string, srcCtrl *control.Source)
- func (a *Agent) HandleMessage(async chan *rpc.Message)
- func (a *Agent) HealthCheck() (alive bool)
- func (a *Agent) InitConfig() (err error)
- func (a *Agent) LoadMultiplexer(multiplexer *map[string][]string) error
- func (a *Agent) LoadSink(sinkName string, sinkType string, eventChan chan *events.LookatchEvent) (err error)
- func (a *Agent) LoadSinks() (err error)
- func (a *Agent) LoadSource(sourceName string, sourceType string, eventChan chan *events.LookatchEvent) (err error)
- func (a *Agent) LoadSources(multiplexer *map[string][]string) (err error)
- func (a *Agent) SendAgentAvailableAction(agentCtrl *control.Agent) error
- func (a *Agent) SendAgentStatus(agentCtrl *control.Agent) error
- func (a *Agent) SendAvailableAction(agentCtrl *control.Agent) (err error)
- func (a *Agent) SendEncapsMessage(msg interface{}, typeMessage string) (err error)
- func (a *Agent) SendMeta(agentCtrl *control.Agent) error
- func (a *Agent) SendSchema(agentCtrl *control.Agent) error
- func (a *Agent) SendSourceAvailableAction(agentCtrl *control.Agent) error
- func (a *Agent) SendSourceStatus(agentCtrl *control.Agent) error
- func (a *Agent) SendStatus(agentCtrl *control.Agent) (err error)
- func (a *Agent) UpdateConfig(agentCtrl *control.Agent) (err error)
- type Auth
- type Controller
- type ControllerConfig
- type Multiplexer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Agent ¶
Agent representation of agent
func (*Agent) ControllerStart ¶
ControllerStart Start Controller
func (*Agent) DispatchAgent ¶
DispatchAgent dispatch agent message
func (*Agent) DispatchSink ¶
DispatchSink dispatch sink message
func (*Agent) DispatchSource ¶
DispatchSource dispatch source message
func (*Agent) GetSchemas ¶
GetSchemas create message of schemas
func (*Agent) GetSourceAvailableAction ¶
GetSourceAvailableAction Controller asked for Available Actions, sending it
func (*Agent) HandleMessage ¶
HandleMessage Handle Message from rpc
func (*Agent) HealthCheck ¶
HealthCheck returns true if agent and all source are up
func (*Agent) LoadMultiplexer ¶
LoadMultiplexer Load Multiplexer
func (*Agent) LoadSink ¶
func (a *Agent) LoadSink(sinkName string, sinkType string, eventChan chan *events.LookatchEvent) (err error)
LoadSink Load Sinks from name
func (*Agent) LoadSource ¶
func (a *Agent) LoadSource(sourceName string, sourceType string, eventChan chan *events.LookatchEvent) (err error)
LoadSource Load Source from name
func (*Agent) LoadSources ¶
LoadSources Load Sources
func (*Agent) SendAgentAvailableAction ¶
SendAgentAvailableAction send agent action
func (*Agent) SendAgentStatus ¶
SendAgentStatus send agent status
func (*Agent) SendAvailableAction ¶
SendAvailableAction send all available action
func (*Agent) SendEncapsMessage ¶
SendEncapsMessage encaspule message and send to rpc
func (*Agent) SendSchema ¶
SendSchema send all sources schema
func (*Agent) SendSourceAvailableAction ¶
SendSourceAvailableAction send source action
func (*Agent) SendSourceStatus ¶
SendSourceStatus send source status
func (*Agent) SendStatus ¶
SendStatus send agent status and source status
type Auth ¶
type Auth struct {
// contains filtered or unexported fields
}
Auth representation of auth
type Controller ¶
type Controller struct { Status string // contains filtered or unexported fields }
Controller representation of controller
func NewControllerClient ¶
func NewControllerClient(conf *viper.Viper, auth *Auth) *Controller
NewControllerClient create new controller client
func (*Controller) RecvMessage ¶
func (c *Controller) RecvMessage(async chan *rpc.Message)
RecvMessage receive message from channel
type ControllerConfig ¶
type ControllerConfig struct { Address string `json:"address"` Port int `json:"port"` Secure bool `json:"secure"` }
ControllerConfig representation of controller config
type Multiplexer ¶
type Multiplexer struct {
// contains filtered or unexported fields
}
Multiplexer representation of Multiplexer
func NewMultiplexer ¶
func NewMultiplexer(in chan *events.LookatchEvent, outs []chan *events.LookatchEvent) (multiplexer *Multiplexer)
NewMultiplexer create new multiplexer