test-errcode
withchao 2 years ago
parent 3c1b0e3994
commit d0c042844e

@ -1,14 +1,14 @@
package main package main
import ( import (
"context" "fmt"
"github.com/OpenIMSDK/Open-IM-Server/internal/rpc/third" "github.com/OpenIMSDK/Open-IM-Server/internal/rpc/third"
"github.com/OpenIMSDK/Open-IM-Server/pkg/common/cmd" "github.com/OpenIMSDK/Open-IM-Server/pkg/common/cmd"
"github.com/OpenIMSDK/Open-IM-Server/pkg/common/config" "github.com/OpenIMSDK/Open-IM-Server/pkg/common/config"
"github.com/OpenIMSDK/Open-IM-Server/pkg/common/log"
) )
func main() { func main() {
fmt.Println("#######################################")
rpcCmd := cmd.NewRpcCmd("third") rpcCmd := cmd.NewRpcCmd("third")
rpcCmd.AddPortFlag() rpcCmd.AddPortFlag()
rpcCmd.AddPrometheusPortFlag() rpcCmd.AddPrometheusPortFlag()
@ -16,7 +16,7 @@ func main() {
panic(err.Error()) panic(err.Error())
} }
name := config.Config.RpcRegisterName.OpenImThirdName name := config.Config.RpcRegisterName.OpenImThirdName
log.ZInfo(context.Background(), "StartRpc", "name", name) fmt.Println("StartThirdRpc", "name:", name)
if err := rpcCmd.StartSvr(name, third.Start); err != nil { if err := rpcCmd.StartSvr(name, third.Start); err != nil {
panic(err.Error()) panic(err.Error())
} }

Loading…
Cancel
Save