add debug log
This commit is contained in:
parent
1dd5461cdd
commit
7cbd3324ee
|
@ -167,7 +167,7 @@ int32_t rpcSendRequest(void* shandle, const SEpSet* pEpSet, SRpcMsg* pMsg, int64
|
|||
return transSendRequest(shandle, pEpSet, pMsg, NULL);
|
||||
}
|
||||
int32_t rpcSendRequestWithCtx(void* shandle, const SEpSet* pEpSet, SRpcMsg* pMsg, int64_t* pRid, SRpcCtx* pCtx) {
|
||||
if (pCtx != NULL || pMsg->info.handle != 0 || pRid == NULL) {
|
||||
if (pCtx != NULL || pMsg->info.handle != 0 || pMsg->info.noResp != 0|| pRid == NULL) {
|
||||
return transSendRequest(shandle, pEpSet, pMsg, pCtx);
|
||||
} else {
|
||||
return transSendRequestWithId(shandle, pEpSet, pMsg, pRid);
|
||||
|
|
|
@ -905,6 +905,8 @@ static int32_t specifyConnRef(SCliConn* conn, bool update, int64_t handle) {
|
|||
conn->refId = exh->refId;
|
||||
taosWUnLockLatch(&exh->latch);
|
||||
|
||||
tDebug("conn %p specified by %"PRId64"", conn, handle);
|
||||
|
||||
(void)transReleaseExHandle(transGetRefMgt(), handle);
|
||||
return 0;
|
||||
}
|
||||
|
@ -1608,6 +1610,7 @@ static void cliHandleFreeById(SCliMsg* pMsg, SCliThrd* pThrd) {
|
|||
if (conn == NULL || conn->refId != refId) {
|
||||
TAOS_CHECK_GOTO(TSDB_CODE_REF_INVALID_ID, NULL, _exception);
|
||||
}
|
||||
tDebug("do free conn %p by id %" PRId64 "", conn, refId);
|
||||
|
||||
int32_t size = transQueueSize(&conn->cliMsgs);
|
||||
if (size == 0) {
|
||||
|
@ -1619,6 +1622,8 @@ static void cliHandleFreeById(SCliMsg* pMsg, SCliThrd* pThrd) {
|
|||
}
|
||||
return;
|
||||
_exception:
|
||||
tDebug("already free conn %p by id %" PRId64"", conn, refId);
|
||||
|
||||
(void)transReleaseExHandle(transGetRefMgt(), refId);
|
||||
destroyCmsg(pMsg);
|
||||
}
|
||||
|
@ -3260,7 +3265,8 @@ int32_t transFreeConnById(void* shandle, int64_t transpointId) {
|
|||
return TSDB_CODE_RPC_MODULE_QUIT;
|
||||
}
|
||||
if (transpointId == 0) {
|
||||
TAOS_CHECK_GOTO(TSDB_CODE_REF_INVALID_ID, NULL, _exception);
|
||||
tDebug("not free by refId:%"PRId64"", transpointId);
|
||||
TAOS_CHECK_GOTO(0, NULL, _exception);
|
||||
}
|
||||
|
||||
SCliThrd* pThrd = transGetWorkThrdFromHandle(pTransInst, transpointId);
|
||||
|
@ -3274,6 +3280,8 @@ int32_t transFreeConnById(void* shandle, int64_t transpointId) {
|
|||
}
|
||||
pCli->type = FreeById;
|
||||
|
||||
tDebug("release conn By refId %" PRId64 "", transpointId);
|
||||
|
||||
STransMsg msg = {.info.handle = (void*)transpointId};
|
||||
|
||||
code = transAsyncSend(pThrd->asyncPool, &pCli->q);
|
||||
|
|
Loading…
Reference in New Issue