支持自定义日志,优化数据返回

This commit is contained in:
duanhf2012
2020-03-31 18:29:00 +08:00
parent 9e74d2bf2a
commit 5344da1276
5 changed files with 50 additions and 33 deletions

View File

@@ -93,6 +93,7 @@ func (slf *Cluster) Start() {
slf.rpcServer.Start(slf.localNodeInfo.ListenAddr)
}
func GetCluster() *Cluster{
return &cluster
}
@@ -143,4 +144,4 @@ func GetRpcClient(nodeId int,serviceMethod string) ([]*rpc.Client,error) {
func GetRpcServer() *rpc.Server{
return &cluster.rpcServer
}
}