more dev
This commit is contained in:
parent
348bef49ec
commit
f830fc2f4c
|
@ -120,7 +120,6 @@ void vnodeQueryClose(SVnode* pVnode);
|
|||
int32_t vnodeGetTableMeta(SVnode* pVnode, SRpcMsg* pMsg, bool direct);
|
||||
int vnodeGetTableCfg(SVnode* pVnode, SRpcMsg* pMsg, bool direct);
|
||||
int32_t vnodeGetBatchMeta(SVnode* pVnode, SRpcMsg* pMsg);
|
||||
int32_t vnodeQueryCompactProgress(SVnode *pVnode, SRpcMsg *pMsg);
|
||||
|
||||
// vnodeCommit.c
|
||||
int32_t vnodeBegin(SVnode* pVnode);
|
||||
|
|
|
@ -374,15 +374,6 @@ _exit:
|
|||
return code;
|
||||
}
|
||||
|
||||
int32_t vnodeQueryCompactProgress(SVnode *pVnode, SRpcMsg *pMsg){
|
||||
SQueryCompactProgressReq req;
|
||||
|
||||
if (tDeserializeSQueryCompactProgressReq(pMsg->pCont, pMsg->contLen, &req)) {
|
||||
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
int32_t vnodeGetLoad(SVnode *pVnode, SVnodeLoad *pLoad) {
|
||||
SSyncState state = syncGetState(pVnode->sync);
|
||||
|
||||
|
@ -432,9 +423,9 @@ void vnodeResetLoad(SVnode *pVnode, SVnodeLoad *pLoad) {
|
|||
"nBatchInsertSuccess");
|
||||
}
|
||||
|
||||
void vnodeGetInfo(void *pVnode, const char **dbname, int32_t *vgId, int64_t* numOfTables, int64_t* numOfNormalTables) {
|
||||
SVnode* pVnodeObj = pVnode;
|
||||
SVnodeCfg* pConf = &pVnodeObj->config;
|
||||
void vnodeGetInfo(void *pVnode, const char **dbname, int32_t *vgId, int64_t *numOfTables, int64_t *numOfNormalTables) {
|
||||
SVnode *pVnodeObj = pVnode;
|
||||
SVnodeCfg *pConf = &pVnodeObj->config;
|
||||
|
||||
if (dbname) {
|
||||
*dbname = pConf->dbname;
|
||||
|
@ -453,7 +444,7 @@ void vnodeGetInfo(void *pVnode, const char **dbname, int32_t *vgId, int64_t* num
|
|||
}
|
||||
}
|
||||
|
||||
int32_t vnodeGetTableList(void* pVnode, int8_t type, SArray* pList) {
|
||||
int32_t vnodeGetTableList(void *pVnode, int8_t type, SArray *pList) {
|
||||
if (type == TSDB_SUPER_TABLE) {
|
||||
return vnodeGetStbIdList(pVnode, 0, pList);
|
||||
} else {
|
||||
|
@ -703,12 +694,12 @@ void *vnodeGetIdx(void *pVnode) {
|
|||
return NULL;
|
||||
}
|
||||
|
||||
return metaGetIdx(((SVnode*)pVnode)->pMeta);
|
||||
return metaGetIdx(((SVnode *)pVnode)->pMeta);
|
||||
}
|
||||
|
||||
void *vnodeGetIvtIdx(void *pVnode) {
|
||||
if (pVnode == NULL) {
|
||||
return NULL;
|
||||
}
|
||||
return metaGetIvtIdx(((SVnode*)pVnode)->pMeta);
|
||||
return metaGetIvtIdx(((SVnode *)pVnode)->pMeta);
|
||||
}
|
||||
|
|
|
@ -22,8 +22,6 @@
|
|||
#include "vnode.h"
|
||||
#include "vnodeInt.h"
|
||||
|
||||
extern int32_t tsdbStopAllCompTask(STsdb *tsdb);
|
||||
|
||||
static int32_t vnodeProcessCreateStbReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
static int32_t vnodeProcessAlterStbReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
static int32_t vnodeProcessDropStbReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
|
@ -44,7 +42,9 @@ static int32_t vnodeProcessCreateIndexReq(SVnode *pVnode, int64_t ver, void *pRe
|
|||
static int32_t vnodeProcessDropIndexReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
static int32_t vnodeProcessCompactVnodeReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
static int32_t vnodeProcessConfigChangeReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
static int32_t vnodeProcessKillCompactReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
|
||||
extern int32_t vnodeProcessKillCompactReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp);
|
||||
extern int32_t vnodeQueryCompactProgress(SVnode *pVnode, SRpcMsg *pMsg);
|
||||
|
||||
static int32_t vnodePreprocessCreateTableReq(SVnode *pVnode, SDecoder *pCoder, int64_t btime, int64_t *pUid) {
|
||||
int32_t code = 0;
|
||||
|
@ -627,15 +627,12 @@ int32_t vnodeProcessWriteMsg(SVnode *pVnode, SRpcMsg *pMsg, int64_t ver, SRpcMsg
|
|||
case TDMT_VND_COMPACT:
|
||||
vnodeProcessCompactVnodeReq(pVnode, ver, pReq, len, pRsp);
|
||||
goto _exit;
|
||||
case TDMT_VND_KILL_COMPACT:
|
||||
vnodeProcessKillCompactReq(pVnode, ver, pReq, len, pRsp);
|
||||
break;
|
||||
case TDMT_SYNC_CONFIG_CHANGE:
|
||||
vnodeProcessConfigChangeReq(pVnode, ver, pReq, len, pRsp);
|
||||
break;
|
||||
#ifndef TD_ENTERPRISE
|
||||
#ifdef TD_ENTERPRISE
|
||||
case TDMT_VND_KILL_COMPACT:
|
||||
tsdbStopAllCompTask(pVnode->pTsdb);
|
||||
vnodeProcessKillCompactReq(pVnode, ver, pReq, len, pRsp);
|
||||
break;
|
||||
#endif
|
||||
default:
|
||||
|
@ -747,8 +744,10 @@ int32_t vnodeProcessFetchMsg(SVnode *pVnode, SRpcMsg *pMsg, SQueueInfo *pInfo) {
|
|||
return vnodeGetTableCfg(pVnode, pMsg, true);
|
||||
case TDMT_VND_BATCH_META:
|
||||
return vnodeGetBatchMeta(pVnode, pMsg);
|
||||
#ifdef TD_ENTERPRISE
|
||||
case TDMT_VND_QUERY_COMPACT_PROGRESS:
|
||||
return vnodeQueryCompactProgress(pVnode, pMsg);
|
||||
#endif
|
||||
// case TDMT_VND_TMQ_CONSUME:
|
||||
// return tqProcessPollReq(pVnode->pTq, pMsg);
|
||||
case TDMT_VND_TMQ_VG_WALINFO:
|
||||
|
@ -2056,15 +2055,6 @@ static int32_t vnodeProcessCompactVnodeReq(SVnode *pVnode, int64_t ver, void *pR
|
|||
return vnodeProcessCompactVnodeReqImpl(pVnode, ver, pReq, len, pRsp);
|
||||
}
|
||||
|
||||
static int32_t vnodeProcessKillCompactReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp){
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int32_t vnodeProcessStopCompactReq(SVnode *pVnode) {
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int32_t vnodeProcessConfigChangeReq(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp) {
|
||||
syncCheckMember(pVnode->sync);
|
||||
|
||||
|
@ -2080,9 +2070,4 @@ static int32_t vnodeProcessConfigChangeReq(SVnode *pVnode, int64_t ver, void *pR
|
|||
int32_t vnodeProcessCompactVnodeReqImpl(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
int32_t vnodeQueryCompactProgress(SVnode *pVnode, int64_t ver, void *pReq, int32_t len, SRpcMsg *pRsp) {
|
||||
// tsdbCompMonitorGetInfo(STsdb * tsdb, SCompMonInfo * info);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue