diff --git a/src/mnode/src/mgmtSdb.c b/src/mnode/src/mgmtSdb.c index 804522d19ad06cc5cbb00183c738fb4da203038b..26afc1c6f0696e8082da65fd5438833034c32e87 100644 --- a/src/mnode/src/mgmtSdb.c +++ b/src/mnode/src/mgmtSdb.c @@ -332,7 +332,7 @@ void sdbIncRef(void *handle, void *pRow) { SSdbTable *pTable = handle; int32_t * pRefCount = (int32_t *)(pRow + pTable->refCountPos); atomic_add_fetch_32(pRefCount, 1); - if (0 && strcmp(pTable->tableName, "accounts") == 0) { + if (0 && pTable->tableId == SDB_TABLE_CTABLE) { sdbTrace("table:%s, add ref to record:%s:%s:%d", pTable->tableName, pTable->tableName, sdbGetkeyStr(pTable, pRow), *pRefCount); } @@ -344,7 +344,7 @@ void sdbDecRef(void *handle, void *pRow) { SSdbTable *pTable = handle; int32_t * pRefCount = (int32_t *)(pRow + pTable->refCountPos); int32_t refCount = atomic_sub_fetch_32(pRefCount, 1); - if (0 && strcmp(pTable->tableName, "accounts") == 0) { + if (0 && pTable->tableId == SDB_TABLE_CTABLE) { sdbTrace("table:%s, def ref of record:%s:%s:%d", pTable->tableName, pTable->tableName, sdbGetkeyStr(pTable, pRow), *pRefCount); } diff --git a/src/mnode/src/mgmtTable.c b/src/mnode/src/mgmtTable.c index 59010da61296f747851ceed0419e46eae810b178..c83c3f1d8dd70ceedb3512cfda92bf56d3ee3d57 100644 --- a/src/mnode/src/mgmtTable.c +++ b/src/mnode/src/mgmtTable.c @@ -41,8 +41,8 @@ #include "mgmtVgroup.h" #include "tcompare.h" -void * tsChildTableSdb; -void * tsSuperTableSdb; +static void * tsChildTableSdb; +static void * tsSuperTableSdb; static int32_t tsChildTableUpdateSize; static int32_t tsSuperTableUpdateSize; static void * mgmtGetChildTable(char *tableId); @@ -361,7 +361,7 @@ static void mgmtCleanUpChildTables() { static void mgmtAddTableIntoStable(SSuperTableObj *pStable, SChildTableObj *pCtable) { if (pStable->vgLen == 0) { - pStable->vgLen = 10; + pStable->vgLen = 8; pStable->vgList = calloc(pStable->vgLen, sizeof(int32_t)); }