Merge branch 'master' of https://www.loafle.net/gitlab/overflow/agent
This commit is contained in:
commit
59593c07e3
8
agent.go
8
agent.go
|
@ -42,6 +42,12 @@ func (agt *Agent) startAgent() {
|
|||
globalConf := <-cfgStarted
|
||||
|
||||
//2. evt start()
|
||||
evtStartChn := make(chan bool, 0)
|
||||
err := evt.Start(evtStartChn)
|
||||
//if err != nil {
|
||||
// processError(err)
|
||||
//}
|
||||
<- evtStartChn
|
||||
//3. dat start()
|
||||
datStarted := make(chan bool)
|
||||
dat.Start(datStarted, globalConf)
|
||||
|
@ -152,6 +158,8 @@ func (agt *Agent) stopAgent() {
|
|||
//evt result
|
||||
evt.AddEventData(msg.TaskResult{msg.AGT_STOP, true, nil })
|
||||
//evt stop()
|
||||
evt.Stop()
|
||||
|
||||
}
|
||||
|
||||
func (agt *Agent) processStartSensor(task msg.AgentTask) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user