From 3b2d69dde3ae175bf00981e0d95e7e8cafd5f3a1 Mon Sep 17 00:00:00 2001 From: sunty <1172534965@qq.com> Date: 星期二, 27 七月 2021 14:45:29 +0800 Subject: [PATCH] Merge branch 'master' of http://192.168.5.5:10010/r/pubsub/esutil --- ClusterApi.go | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/ClusterApi.go b/ClusterApi.go index bdae03a..c41143c 100644 --- a/ClusterApi.go +++ b/ClusterApi.go @@ -55,6 +55,7 @@ if resultMsg == "杩愯澶辫触" { return true } + time.Sleep(time.Second * 3) } bs := VerifyShortNodeServer(ip, port) return bs @@ -99,7 +100,7 @@ } //楠岃瘉鑺傜偣鏈嶅姟鏄惁姝e父鍚姩 -func VerifyNodeServer(ip string, port string) bool { +func VerifyNodeServer(ip string, port string, waitTime int) bool { b := false url := "http://" + ip + ":" + port for i := 1; i < 3; i++ { @@ -107,7 +108,7 @@ if err != nil { b = false if i < 3 { - time.Sleep(time.Second * 10) + time.Sleep(time.Second * time.Duration(waitTime)) continue } } else { -- Gitblit v1.8.0