Skip to content

Commit

Permalink
enh: add dangle child table filter in recovery mode
Browse files Browse the repository at this point in the history
  • Loading branch information
hzcheng committed Nov 15, 2024
1 parent 1120383 commit 0c45c80
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion source/dnode/vnode/src/meta/metaOpen.c
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,11 @@ static int32_t metaGenerateNewMeta(SMeta **ppMeta) {
SMetaEntry me = {0};
tDecoderInit(&dc, value, valueSize);
if (metaDecodeEntry(&dc, &me) == 0) {
if (metaHandleEntry(pNewMeta, &me) != 0) {
if (me.type == TSDB_CHILD_TABLE &&
tdbTbGet(pMeta->pUidIdx, &me.ctbEntry.suid, sizeof(me.ctbEntry.suid), NULL, NULL) != 0) {
metaError("vgId:%d failed to get super table uid:%" PRId64 " for child table uid:%" PRId64,
TD_VID(pVnode), me.ctbEntry.suid, uid);
} else if (metaHandleEntry(pNewMeta, &me) != 0) {
metaError("vgId:%d failed to handle entry, uid:%" PRId64, TD_VID(pVnode), uid);
}
}
Expand Down

0 comments on commit 0c45c80

Please sign in to comment.