This commit is contained in:
suyl
2021-06-28 18:42:20 +08:00
parent 360e274e60
commit 0540488e2f
2 changed files with 5 additions and 1 deletions

View File

@@ -48,7 +48,7 @@ type TcpClient struct {
s *sync.RWMutex s *sync.RWMutex
} }
func init() { func Init() {
listenTcp() listenTcp()
go handleTcpMessages() go handleTcpMessages()
} }

View File

@@ -3,6 +3,7 @@ package main
import ( import (
"flag" "flag"
"fmt" "fmt"
"git.rosy.net.cn/jx-callback/business/jxstore/event"
"net/http" "net/http"
_ "net/http/pprof" _ "net/http/pprof"
"os" "os"
@@ -143,6 +144,9 @@ func main() {
http.ListenAndServe("0.0.0.0:6060", nil) http.ListenAndServe("0.0.0.0:6060", nil)
} }
}() }()
if globals.IsProductEnv() {
event.Init()
}
beego.Run() beego.Run()
} }
} }