sunty
2020-10-19 d79aeafde72f87315161adf9ce3c174c6e2b0ad6
completion stop server
1个文件已修改
13 ■■■■ 已修改文件
ClusterApi.go 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ClusterApi.go
@@ -40,8 +40,15 @@
}
//关闭服务
func StopServer(binPath string) {
func StopServer(pidPath string, ip string, port string) bool {
    bool := VerifyShortNodeServer(ip, port)
    if bool == true {
        resultMsg := CMDSC("kill `cat " + pidPath + "pid`")
        if resultMsg == "运行失败" {
            return false
        }
    }
    return true
}
//更换节点角色
@@ -148,7 +155,7 @@
    if err := v.WriteConfig(); err != nil {
        return false, err
    }
    return true,nil
    return true, nil
}
//更新组播列表