Merge pull request #19422 from taosdata/fix/TD-21756
fix(vnd/snap): keep vnode stats transfered from leader
This commit is contained in:
commit
8ebd94aab8
|
@ -406,8 +406,10 @@ static int32_t vnodeSnapWriteInfo(SVSnapWriter *pWriter, uint8_t *pData, uint32_
|
||||||
snprintf(dir, TSDB_FILENAME_LEN, "%s", pWriter->pVnode->path);
|
snprintf(dir, TSDB_FILENAME_LEN, "%s", pWriter->pVnode->path);
|
||||||
}
|
}
|
||||||
|
|
||||||
SVnode *pVnode = pWriter->pVnode;
|
SVnodeStats vndStats = pWriter->info.config.vndStats;
|
||||||
|
SVnode *pVnode = pWriter->pVnode;
|
||||||
pWriter->info.config = pVnode->config;
|
pWriter->info.config = pVnode->config;
|
||||||
|
pWriter->info.config.vndStats = vndStats;
|
||||||
vDebug("vgId:%d, save config while write snapshot", pWriter->pVnode->config.vgId);
|
vDebug("vgId:%d, save config while write snapshot", pWriter->pVnode->config.vgId);
|
||||||
if (vnodeSaveInfo(dir, &pWriter->info) < 0) {
|
if (vnodeSaveInfo(dir, &pWriter->info) < 0) {
|
||||||
code = terrno;
|
code = terrno;
|
||||||
|
|
Loading…
Reference in New Issue