From e2e782d7248b845310b8fb2125cce4d8cc52baec Mon Sep 17 00:00:00 2001 From: kailixu Date: Mon, 26 Aug 2024 11:30:56 +0800 Subject: [PATCH] enh: remove assert --- source/dnode/vnode/src/sma/smaRollup.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/source/dnode/vnode/src/sma/smaRollup.c b/source/dnode/vnode/src/sma/smaRollup.c index 4acdc3e92c..d77b933e28 100644 --- a/source/dnode/vnode/src/sma/smaRollup.c +++ b/source/dnode/vnode/src/sma/smaRollup.c @@ -1430,7 +1430,7 @@ static void tdFreeRSmaSubmitItems(SArray *pItems, int32_t type) { blockDataDestroy(packData->pDataBlock); } } else { - ASSERTS(0, "unknown type:%d", type); + smaWarn("%s:%d unknown type:%d", __func__, __LINE__, type); } taosArrayClear(pItems); } @@ -1540,14 +1540,13 @@ static int32_t tdRSmaBatchExec(SSma *pSma, SRSmaInfo *pInfo, STaosQall *qall, SA ++nDelete; } } else { - ASSERTS(0, "unknown msg type:%d", inputType); + smaWarn("%s:%d unknown msg type:%d", __func__, __LINE__, inputType); break; } } if (nSubmit > 0 || nDelete > 0) { int32_t size = TARRAY_SIZE(pSubmitArr); - ASSERTS(size > 0, "size is %d", size); int32_t inputType = nSubmit > 0 ? STREAM_INPUT__MERGED_SUBMIT : STREAM_INPUT__REF_DATA_BLOCK; for (int32_t i = 1; i <= TSDB_RETENTION_L2; ++i) { TAOS_CHECK_EXIT(tdExecuteRSmaImpl(pSma, pSubmitArr->pData, size, version, inputType, pInfo, type, i)); @@ -1677,7 +1676,7 @@ int32_t tdRSmaProcessExecImpl(SSma *pSma, ERsmaExecType type) { } } } else { - ASSERTS(0, "unknown rsma exec type:%d", (int32_t)type); + smaWarn("%s:%d unknown rsma exec type:%d", __func__, __LINE__, (int32_t)type); code = TSDB_CODE_APP_ERROR; TSDB_CHECK_CODE(code, lino, _exit); }