diff --git a/business/jxstore/event/event_tcp.go b/business/jxstore/event/event_tcp.go index e2f782b0a..bc83e199e 100644 --- a/business/jxstore/event/event_tcp.go +++ b/business/jxstore/event/event_tcp.go @@ -142,6 +142,9 @@ func ListenTcp() { return } globals.SugarLogger.Debugf("begin listenTcp port 8000......") + go HandleTcpMessages() + go HandleCheckTcpHeart() + go doPrint2(printMsgChan) //go doPrint(printMsgChanFail) for { c, err := l.Accept() @@ -152,11 +155,6 @@ func ListenTcp() { go handleConn(c) } } -func Run() { - go HandleTcpMessages() - go HandleCheckTcpHeart() - go doPrint2(printMsgChan) -} func handleConn(c net.Conn) { var ( diff --git a/main.go b/main.go index 9bc7e68d8..bd1bc089b 100644 --- a/main.go +++ b/main.go @@ -129,7 +129,6 @@ func main() { } }() if globals.IsPrintEnv() { - event.Run() event.ListenTcp() } beego.Run()