feat(log): 在控制台输出日志
This commit is contained in:
@@ -4,6 +4,7 @@ package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"os"
|
||||
"time"
|
||||
|
||||
"github.com/cloudwego/hertz/pkg/app"
|
||||
@@ -59,6 +60,7 @@ func registerMiddleware(h *server.Hertz) {
|
||||
h.OnShutdown = append(h.OnShutdown, func(ctx context.Context) {
|
||||
asyncWriter.Sync()
|
||||
})
|
||||
hlog.SetOutput(os.Stdout)
|
||||
|
||||
// pprof
|
||||
if conf.GetConf().Hertz.EnablePprof {
|
||||
|
||||
Reference in New Issue
Block a user