From d671283b8be9412f76027d2913f51d7387cd1aab Mon Sep 17 00:00:00 2001 From: Benguang Zhao Date: Sun, 8 Oct 2023 17:41:33 +0800 Subject: [PATCH] refact: adjust logging msg for incomplete fsm state --- source/libs/sync/src/syncAppendEntries.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/libs/sync/src/syncAppendEntries.c b/source/libs/sync/src/syncAppendEntries.c index 4776b2bb1b..647b86bae9 100644 --- a/source/libs/sync/src/syncAppendEntries.c +++ b/source/libs/sync/src/syncAppendEntries.c @@ -155,9 +155,9 @@ int32_t syncNodeOnAppendEntries(SSyncNode* ths, const SRpcMsg* pRpcMsg) { pMsg->vgId, pMsg->prevLogIndex + 1, pMsg->term, pMsg->prevLogIndex, pMsg->prevLogTerm, pMsg->commitIndex, pEntry->term); - if (ths->fsmState == SYNC_FSM_STATE_INCOMPLETE) { + if (ths->fsmState != SYNC_FSM_STATE_NORMAL) { pReply->fsmState = ths->fsmState; - sError("vgId:%d, not to accept sync log msg due to incomplete fsm state", ths->vgId); + sWarn("vgId:%d, unable to accept, due to incomplete fsm state. index:%" PRId64, ths->vgId, pEntry->index); syncEntryDestroy(pEntry); goto _SEND_RESPONSE; }