data_sender_go/data_sender_event.go

21 lines
470 B
Go
Raw Normal View History

2017-05-11 09:58:19 +00:00
package data_sender_go
import (
"loafle.com/overflow/agent_api/observer"
"loafle.com/overflow/agent_api/observer/messages"
)
func handleConfigLoaded() {
ch := make(chan interface{}, 0)
observer.Add(messages.CFG_LOADED, ch)
startDataSender(ch)
2017-05-11 11:07:31 +00:00
//observer.Remove(messages.CFG_LOADED, ch)
2017-05-11 09:58:19 +00:00
}
func (ds *DataSender) handleAgentStop() {
ch := make(chan interface{}, 0)
observer.Add(messages.AGT_STOPPED, ch)
ds.Stop()
2017-05-11 11:07:31 +00:00
//observer.Remove(messages.AGT_STOPPED, ch)
2017-05-11 09:58:19 +00:00
}