xuzhiheng 1 năm trước cách đây
mục cha
commit
c6be14dd68
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      rpc/biservice.go

+ 1 - 1
rpc/biservice.go

@@ -28,6 +28,7 @@ func main() {
 	conf.MustLoad(*configFile, &c)
 	ctx := svc.NewServiceContext(c)
 	srv := server.NewBiServiceServer(ctx)
+	logx.MustSetup(c.Logx)
 	entity.PublicKey = c.PublicKey
 	entity.InitMysql(c.Mysql.JianYu, c.Mysql.JyDoc, c.Mysql.Bi, c.Mysql.Tidb, c.Mysql.BiTidb, c.Mysql.CallTidb, c.Mysql.BiService)
 	entity.InitMail(c.Mail)
@@ -56,7 +57,6 @@ func main() {
 	s := zrpc.MustNewServer(c.RpcServerConf, func(grpcServer *grpc.Server) {
 		pb.RegisterBiServiceServer(grpcServer, srv)
 	})
-	logx.MustSetup(c.Logx)
 	defer s.Stop()
 
 	fmt.Printf("Starting rpc server at %s...\n", c.ListenOn)