debug
This commit is contained in:
parent
aad937f0d6
commit
d5ff9a9c4e
@ -166,10 +166,10 @@ func MQKeepAliveWorker() {
|
|||||||
} else if clt, ok := getLockedClient(x.TGUserID64, true); ok {
|
} else if clt, ok := getLockedClient(x.TGUserID64, true); ok {
|
||||||
clt.HeartBeat = x.Date
|
clt.HeartBeat = x.Date
|
||||||
if clt.Active {
|
if clt.Active {
|
||||||
log.Printf("MQKeepAliveWorker : Client already active.\n")
|
log.Printf("MQKeepAliveWorker : Client %s already active.\n", x.Nickname)
|
||||||
clt.Mux.Unlock()
|
clt.Mux.Unlock()
|
||||||
} else {
|
} else {
|
||||||
log.Printf("MQKeepAliveWorker : Connecting client.\n")
|
log.Printf("MQKeepAliveWorker : Connecting to %s.\n", x.Nickname)
|
||||||
clt.MQ = MQClient{
|
clt.MQ = MQClient{
|
||||||
User: cfg.Rabbit.User,
|
User: cfg.Rabbit.User,
|
||||||
Password: cfg.Rabbit.Password,
|
Password: cfg.Rabbit.Password,
|
||||||
@ -202,6 +202,7 @@ func MQKeepAliveWorker() {
|
|||||||
clt.MQ.Connection.Close()
|
clt.MQ.Connection.Close()
|
||||||
} else {
|
} else {
|
||||||
clt.Active = true
|
clt.Active = true
|
||||||
|
log.Printf("MQKeepAliveWorker : Connected to %s.\n", x.Nickname)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user