refactor(sync): delete code wait snapshot end in pre-close
This commit is contained in:
parent
b6f1ce2027
commit
86d5cba6be
|
@ -491,7 +491,7 @@ void mndPreClose(SMnode *pMnode) {
|
||||||
if (pMnode != NULL) {
|
if (pMnode != NULL) {
|
||||||
syncLeaderTransfer(pMnode->syncMgmt.sync);
|
syncLeaderTransfer(pMnode->syncMgmt.sync);
|
||||||
syncPreStop(pMnode->syncMgmt.sync);
|
syncPreStop(pMnode->syncMgmt.sync);
|
||||||
|
#if 0
|
||||||
while (syncSnapshotRecving(pMnode->syncMgmt.sync)) {
|
while (syncSnapshotRecving(pMnode->syncMgmt.sync)) {
|
||||||
mInfo("vgId:1, snapshot is recving");
|
mInfo("vgId:1, snapshot is recving");
|
||||||
taosMsleep(300);
|
taosMsleep(300);
|
||||||
|
@ -500,6 +500,7 @@ void mndPreClose(SMnode *pMnode) {
|
||||||
mInfo("vgId:1, snapshot is sending");
|
mInfo("vgId:1, snapshot is sending");
|
||||||
taosMsleep(300);
|
taosMsleep(300);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -515,7 +515,7 @@ void vnodeSyncPreClose(SVnode *pVnode) {
|
||||||
vInfo("vgId:%d, pre close sync", pVnode->config.vgId);
|
vInfo("vgId:%d, pre close sync", pVnode->config.vgId);
|
||||||
syncLeaderTransfer(pVnode->sync);
|
syncLeaderTransfer(pVnode->sync);
|
||||||
syncPreStop(pVnode->sync);
|
syncPreStop(pVnode->sync);
|
||||||
|
#if 0
|
||||||
while (syncSnapshotRecving(pVnode->sync)) {
|
while (syncSnapshotRecving(pVnode->sync)) {
|
||||||
vInfo("vgId:%d, snapshot is recving", pVnode->config.vgId);
|
vInfo("vgId:%d, snapshot is recving", pVnode->config.vgId);
|
||||||
taosMsleep(300);
|
taosMsleep(300);
|
||||||
|
@ -524,7 +524,7 @@ void vnodeSyncPreClose(SVnode *pVnode) {
|
||||||
vInfo("vgId:%d, snapshot is sending", pVnode->config.vgId);
|
vInfo("vgId:%d, snapshot is sending", pVnode->config.vgId);
|
||||||
taosMsleep(300);
|
taosMsleep(300);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
taosThreadMutexLock(&pVnode->lock);
|
taosThreadMutexLock(&pVnode->lock);
|
||||||
if (pVnode->blocked) {
|
if (pVnode->blocked) {
|
||||||
vInfo("vgId:%d, post block after close sync", pVnode->config.vgId);
|
vInfo("vgId:%d, post block after close sync", pVnode->config.vgId);
|
||||||
|
|
Loading…
Reference in New Issue