Merge branch 'master' of https://github.com/didi/nightingale
This commit is contained in:
commit
5bb48df01d
|
@ -97,6 +97,10 @@ func main() {
|
|||
go worker.PusherStart()
|
||||
go worker.Zeroize()
|
||||
|
||||
if cfg.Logger.Level != "DEBUG" {
|
||||
gin.SetMode(gin.ReleaseMode)
|
||||
}
|
||||
|
||||
r := gin.New()
|
||||
routes.Config(r)
|
||||
http.Start(r, "collector", cfg.Logger.Level)
|
||||
|
|
|
@ -80,6 +80,10 @@ func main() {
|
|||
go judge.NodataJudge(cfg.NodataConcurrency)
|
||||
go report.Init(cfg.Report, "monapi")
|
||||
|
||||
if cfg.Logger.Level != "DEBUG" {
|
||||
gin.SetMode(gin.ReleaseMode)
|
||||
}
|
||||
|
||||
r := gin.New()
|
||||
routes.Config(r)
|
||||
go http.Start(r, "judge", cfg.Logger.Level)
|
||||
|
|
|
@ -25,7 +25,6 @@ func Start(r *gin.Engine, mod string, level string) {
|
|||
recoveryMid := middleware.Recovery()
|
||||
|
||||
if level != "DEBUG" {
|
||||
gin.SetMode(gin.ReleaseMode)
|
||||
middleware.DisableConsoleColor()
|
||||
} else {
|
||||
srv.WriteTimeout = 120 * time.Second
|
||||
|
|
Loading…
Reference in New Issue