diff --git a/src/mnode/src/mnodeProfile.c b/src/mnode/src/mnodeProfile.c index 85457d7a26b84adfd383d447c84604c15a436cee..01a824baa78a9bb109a22e3090e2fd21e5b68850 100644 --- a/src/mnode/src/mnodeProfile.c +++ b/src/mnode/src/mnodeProfile.c @@ -35,8 +35,8 @@ #include "mnodeVgroup.h" #include "mnodeWrite.h" -#define CONN_KEEP_TIME (tsShellActivityTimer * 3) -#define CONN_CHECK_TIME (tsShellActivityTimer * 2) +#define CONN_KEEP_TIME (tsShellActivityTimer * 3000) +#define CONN_CHECK_TIME (tsShellActivityTimer * 2000) #define QUERY_ID_SIZE 20 #define QUERY_STREAM_SAVE_SIZE 20 diff --git a/src/mnode/src/mnodeShow.c b/src/mnode/src/mnodeShow.c index 9983c111f60602b00fd60749c6d17f86f7bf1a63..aec946722fd0f55c1323c3e86ca76cf1cc7a05c4 100644 --- a/src/mnode/src/mnodeShow.c +++ b/src/mnode/src/mnodeShow.c @@ -389,7 +389,7 @@ static bool mnodeAccquireShowObj(SShowObj *pShow) { static void* mnodePutShowObj(SShowObj *pShow) { if (tsMnodeShowCache != NULL) { pShow->index = atomic_add_fetch_32(&tsShowObjIndex, 1); - SShowObj **ppShow = taosCachePut(tsMnodeShowCache, &pShow, sizeof(int64_t), &pShow, sizeof(int64_t), 6); + SShowObj **ppShow = taosCachePut(tsMnodeShowCache, &pShow, sizeof(int64_t), &pShow, sizeof(int64_t), 6000); pShow->ppShow = (void**)ppShow; mDebug("%p, show is put into cache, data:%p index:%d", pShow, ppShow, pShow->index); return pShow; diff --git a/src/plugins/http/src/httpContext.c b/src/plugins/http/src/httpContext.c index ad0d302c8249065c95398bb76cda139e6bee7fac..38b829e406c2eb1cd3a0dd40e603e488d29cf5a2 100644 --- a/src/plugins/http/src/httpContext.c +++ b/src/plugins/http/src/httpContext.c @@ -108,7 +108,7 @@ HttpContext *httpCreateContext(int32_t fd) { pContext->lastAccessTime = taosGetTimestampSec(); pContext->state = HTTP_CONTEXT_STATE_READY; - HttpContext **ppContext = taosCachePut(tsHttpServer.contextCache, &pContext, sizeof(int64_t), &pContext, sizeof(int64_t), 3); + HttpContext **ppContext = taosCachePut(tsHttpServer.contextCache, &pContext, sizeof(int64_t), &pContext, sizeof(int64_t), 3000); pContext->ppContext = ppContext; httpDebug("context:%p, fd:%d, is created, data:%p", pContext, fd, ppContext); diff --git a/src/plugins/http/src/httpSession.c b/src/plugins/http/src/httpSession.c index ad57f0fc29527a09c66047d77a6f7126bfa17f27..f19679e0723cb392dfb78040424b7f7e02913fcc 100644 --- a/src/plugins/http/src/httpSession.c +++ b/src/plugins/http/src/httpSession.c @@ -34,7 +34,7 @@ void httpCreateSession(HttpContext *pContext, void *taos) { session.refCount = 1; int32_t len = snprintf(session.id, HTTP_SESSION_ID_LEN, "%s.%s", pContext->user, pContext->pass); - pContext->session = taosCachePut(server->sessionCache, session.id, len, &session, sizeof(HttpSession), tsHttpSessionExpire); + pContext->session = taosCachePut(server->sessionCache, session.id, len, &session, sizeof(HttpSession), tsHttpSessionExpire * 1000); // void *temp = pContext->session; // taosCacheRelease(server->sessionCache, (void **)&temp, false);