diff --git a/api/simulation.go b/api/simulation.go index 52be561..4818d75 100644 --- a/api/simulation.go +++ b/api/simulation.go @@ -43,7 +43,6 @@ func InitSimulationRouter(api *gin.RouterGroup, authMiddleware *jwt.GinJWTMiddle // 初始化地图信息 initPublishMapInfo() - apiproto.InitClient() apiproto.Register(&apiproto.SimulationServer{}) apiproto.Register(&apiproto.SimulationIBPServer{}) apiproto.Register(&apiproto.SimulationPSLServer{}) diff --git a/main.go b/main.go index c52ec08..7998a8d 100644 --- a/main.go +++ b/main.go @@ -8,6 +8,7 @@ import ( "joylink.club/bj-rtsts-server/api" "joylink.club/bj-rtsts-server/config" "joylink.club/bj-rtsts-server/docs" + apiproto "joylink.club/bj-rtsts-server/grpcproto" "joylink.club/bj-rtsts-server/middleware" "joylink.club/bj-rtsts-server/third_party" @@ -26,6 +27,7 @@ import ( func main() { engine := InitServer() + apiproto.InitClient() third_party.Init() authMiddleware := middleware.InitGinJwtMiddleware() router := engine.Group("/api")