enh: reset sync log replication on stagnation for eight times maxRetryWaitMs
This commit is contained in:
parent
4718f4d1b6
commit
eb524e610a
|
@ -631,7 +631,12 @@ int32_t syncLogReplMgrRetryOnNeed(SSyncLogReplMgr* pMgr, SSyncNode* pNode) {
|
|||
break;
|
||||
}
|
||||
|
||||
if (pMgr->states[pos].acked && nowMs < pMgr->states[pos].timeMs + syncGetRetryMaxWaitMs()) {
|
||||
if (pMgr->states[pos].acked) {
|
||||
if (pMgr->states[pos].timeMs + (syncGetRetryMaxWaitMs() << 3) < nowMs) {
|
||||
syncLogReplMgrReset(pMgr);
|
||||
sWarn("vgId:%d, reset sync log repl mgr since stagnation. peer: %" PRIx64, pNode->vgId, pDestId->addr);
|
||||
goto _out;
|
||||
}
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue