未验证 提交 8ebd94aa 编写于 作者: S Shengliang Guan 提交者: GitHub

Merge pull request #19422 from taosdata/fix/TD-21756

fix(vnd/snap): keep vnode stats transfered from leader
...@@ -406,8 +406,10 @@ static int32_t vnodeSnapWriteInfo(SVSnapWriter *pWriter, uint8_t *pData, uint32_ ...@@ -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;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册