MCPcopy Index your code
hub / github.com/CodisLabs/codis / AutoOnlineWithDashboard

Function AutoOnlineWithDashboard

cmd/proxy/main.go:284–295  ·  view source on GitHub ↗
(p *proxy.Proxy, dashboard string)

Source from the content-addressed store, hash-verified

282}
283
284func AutoOnlineWithDashboard(p *proxy.Proxy, dashboard string) {
285 for i := 0; i < 10; i++ {
286 if p.IsClosed() || p.IsOnline() {
287 return
288 }
289 if OnlineProxy(p, dashboard) {
290 return
291 }
292 time.Sleep(time.Second * 3)
293 }
294 log.Panicf("online proxy failed")
295}
296
297func AutoOnlineWithCoordinator(p *proxy.Proxy, name, addr, auth string) {
298 client, err := models.NewClient(name, addr, auth, time.Minute)

Callers 1

mainFunction · 0.85

Calls 5

OnlineProxyFunction · 0.85
PanicfMethod · 0.80
SleepMethod · 0.65
IsClosedMethod · 0.45
IsOnlineMethod · 0.45

Tested by

no test coverage detected