Merge pull request #19436 from taosdata/FIX/TD-21812-main
fix: use pInfo->info.state.committed for WAL snapshot instead of the current one for async vnodeCommit
This commit is contained in:
commit
704c8e90fb
|
@ -329,8 +329,7 @@ static int vnodeCommitImpl(SCommitInfo *pInfo) {
|
||||||
snprintf(dir, TSDB_FILENAME_LEN, "%s", pVnode->path);
|
snprintf(dir, TSDB_FILENAME_LEN, "%s", pVnode->path);
|
||||||
}
|
}
|
||||||
|
|
||||||
// walBeginSnapshot(pVnode->pWal, pVnode->state.applied);
|
syncBeginSnapshot(pVnode->sync, pInfo->info.state.committed);
|
||||||
syncBeginSnapshot(pVnode->sync, pVnode->state.applied);
|
|
||||||
|
|
||||||
// commit each sub-system
|
// commit each sub-system
|
||||||
code = tsdbCommit(pVnode->pTsdb, pInfo);
|
code = tsdbCommit(pVnode->pTsdb, pInfo);
|
||||||
|
@ -372,7 +371,6 @@ static int vnodeCommitImpl(SCommitInfo *pInfo) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
// walEndSnapshot(pVnode->pWal);
|
|
||||||
syncEndSnapshot(pVnode->sync);
|
syncEndSnapshot(pVnode->sync);
|
||||||
|
|
||||||
_exit:
|
_exit:
|
||||||
|
|
Loading…
Reference in New Issue