ing
This commit is contained in:
parent
33c01a5e3c
commit
2b4c818883
|
@ -135,14 +135,20 @@ RC_LOOP:
|
|||
continue RC_LOOP
|
||||
}
|
||||
|
||||
logging.Logger().Debugf("connection lost")
|
||||
|
||||
for indexI := 0; indexI < c.ReconnectTryTime; indexI++ {
|
||||
logging.Logger().Debugf("trying reconnect[%d]", indexI)
|
||||
|
||||
conn, _, err := c.connect()
|
||||
if nil == err {
|
||||
logging.Logger().Debugf("reconnected")
|
||||
c.reconnectedChan <- conn
|
||||
continue RC_LOOP
|
||||
}
|
||||
time.Sleep(c.ReconnectInterval)
|
||||
}
|
||||
logging.Logger().Debugf("reconnecting has been failed")
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user