Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
4c999f74
T
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1187
Star
22018
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
4c999f74
编写于
3月 21, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Enabling qnodes to process messages
上级
4d842cb1
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
185 addition
and
140 deletion
+185
-140
source/dnode/mgmt/container/inc/dnd.h
source/dnode/mgmt/container/inc/dnd.h
+5
-1
source/dnode/mgmt/container/src/dndInt.c
source/dnode/mgmt/container/src/dndInt.c
+2
-1
source/dnode/mgmt/container/src/dndTransport.c
source/dnode/mgmt/container/src/dndTransport.c
+41
-13
source/dnode/mgmt/dnode/src/dmMsg.c
source/dnode/mgmt/dnode/src/dmMsg.c
+13
-13
source/dnode/mgmt/mnode/src/mmMsg.c
source/dnode/mgmt/mnode/src/mmMsg.c
+70
-70
source/dnode/mgmt/qnode/src/qmMsg.c
source/dnode/mgmt/qnode/src/qmMsg.c
+13
-1
source/dnode/mgmt/snode/src/smMsg.c
source/dnode/mgmt/snode/src/smMsg.c
+2
-2
source/dnode/mgmt/vnode/src/vmMsg.c
source/dnode/mgmt/vnode/src/vmMsg.c
+38
-38
source/dnode/mgmt/vnode/src/vmWorker.c
source/dnode/mgmt/vnode/src/vmWorker.c
+1
-1
未找到文件。
source/dnode/mgmt/container/inc/dnd.h
浏览文件 @
4c999f74
...
...
@@ -89,6 +89,9 @@ typedef struct {
}
SDnodeWorker
;
typedef
struct
SMsgHandle
{
int32_t
vgId
;
NodeMsgFp
vgIdMsgFp
;
SMgmtWrapper
*
pVgIdWrapper
;
// Handle the case where the same message type is distributed to qnode or vnode
NodeMsgFp
msgFp
;
SMgmtWrapper
*
pWrapper
;
}
SMsgHandle
;
...
...
@@ -114,6 +117,7 @@ typedef struct SMgmtWrapper {
void
*
pMgmt
;
SDnode
*
pDnode
;
NodeMsgFp
msgFps
[
TDMT_MAX
];
int32_t
msgVgIds
[
TDMT_MAX
];
// Handle the case where the same message type is distributed to qnode or vnode
SMgmtFp
fp
;
}
SMgmtWrapper
;
...
...
@@ -149,7 +153,7 @@ typedef struct SDnode {
EDndStatus
dndGetStatus
(
SDnode
*
pDnode
);
void
dndSetStatus
(
SDnode
*
pDnode
,
EDndStatus
stat
);
SMgmtWrapper
*
dndAcquireWrapper
(
SDnode
*
pDnode
,
ENodeType
nodeType
);
void
dndSetMsgHandle
(
SMgmtWrapper
*
pWrapper
,
int32_t
msgType
,
NodeMsgFp
nodeMsgFp
);
void
dndSetMsgHandle
(
SMgmtWrapper
*
pWrapper
,
int32_t
msgType
,
NodeMsgFp
nodeMsgFp
,
int32_t
vgId
);
void
dndReportStartup
(
SDnode
*
pDnode
,
char
*
pName
,
char
*
pDesc
);
void
dndSendMonitorReport
(
SDnode
*
pDnode
);
...
...
source/dnode/mgmt/container/src/dndInt.c
浏览文件 @
4c999f74
...
...
@@ -65,8 +65,9 @@ void dndCleanup() {
dInfo
(
"dnode env is cleaned up"
);
}
void
dndSetMsgHandle
(
SMgmtWrapper
*
pWrapper
,
int32_t
msgType
,
NodeMsgFp
nodeMsgFp
)
{
void
dndSetMsgHandle
(
SMgmtWrapper
*
pWrapper
,
int32_t
msgType
,
NodeMsgFp
nodeMsgFp
,
int32_t
vgId
)
{
pWrapper
->
msgFps
[
TMSG_INDEX
(
msgType
)]
=
nodeMsgFp
;
pWrapper
->
msgVgIds
[
TMSG_INDEX
(
msgType
)]
=
vgId
;
}
EDndStatus
dndGetStatus
(
SDnode
*
pDnode
)
{
return
pDnode
->
status
;
}
...
...
source/dnode/mgmt/container/src/dndTransport.c
浏览文件 @
4c999f74
...
...
@@ -20,13 +20,26 @@
#define INTERNAL_CKEY "_key"
#define INTERNAL_SECRET "_pwd"
static
inline
void
dndProcessQVnodeRpcMsg
(
SMsgHandle
*
pHandle
,
SRpcMsg
*
pMsg
,
SEpSet
*
pEpSet
)
{
SMsgHead
*
pHead
=
pMsg
->
pCont
;
int32_t
vgId
=
htonl
(
pHead
->
vgId
);
SMgmtWrapper
*
pWrapper
=
pHandle
->
pWrapper
;
if
(
vgId
==
pHandle
->
vgId
&&
pHandle
->
pVgIdWrapper
!=
NULL
)
{
pWrapper
=
pHandle
->
pVgIdWrapper
;
}
dTrace
(
"msg:%s will be processed by %s, handle:%p app:%p vgId:%d"
,
TMSG_INFO
(
pMsg
->
msgType
),
pWrapper
->
name
,
pMsg
->
handle
,
pMsg
->
ahandle
,
vgId
);
dndProcessRpcMsg
(
pWrapper
,
pMsg
,
pEpSet
);
}
static
void
dndProcessResponse
(
void
*
parent
,
SRpcMsg
*
pRsp
,
SEpSet
*
pEpSet
)
{
SDnode
*
pDnode
=
parent
;
STransMgmt
*
pMgmt
=
&
pDnode
->
trans
;
tmsg_t
msgType
=
pRsp
->
msgType
;
if
(
dndGetStatus
(
pDnode
)
!=
DND_STAT_RUNNING
)
{
// if (pRsp == NULL || pRsp->pCont == NULL) return;
dTrace
(
"rsp:%s ignored since dnode not running, handle:%p app:%p"
,
TMSG_INFO
(
msgType
),
pRsp
->
handle
,
pRsp
->
ahandle
);
rpcFreeCont
(
pRsp
->
pCont
);
return
;
...
...
@@ -34,9 +47,13 @@ static void dndProcessResponse(void *parent, SRpcMsg *pRsp, SEpSet *pEpSet) {
SMsgHandle
*
pHandle
=
&
pMgmt
->
msgHandles
[
TMSG_INDEX
(
msgType
)];
if
(
pHandle
->
msgFp
!=
NULL
)
{
dTrace
(
"rsp:%s will be processed by %s, handle:%p app:%p code:0x%04x:%s"
,
TMSG_INFO
(
msgType
),
pHandle
->
pWrapper
->
name
,
pRsp
->
handle
,
pRsp
->
ahandle
,
pRsp
->
code
&
0XFFFF
,
tstrerror
(
pRsp
->
code
));
dndProcessRpcMsg
(
pHandle
->
pWrapper
,
pRsp
,
pEpSet
);
if
(
pHandle
->
vgId
==
0
)
{
dTrace
(
"rsp:%s will be processed by %s, handle:%p app:%p code:0x%04x:%s"
,
TMSG_INFO
(
msgType
),
pHandle
->
pWrapper
->
name
,
pRsp
->
handle
,
pRsp
->
ahandle
,
pRsp
->
code
&
0XFFFF
,
tstrerror
(
pRsp
->
code
));
dndProcessRpcMsg
(
pHandle
->
pWrapper
,
pRsp
,
pEpSet
);
}
else
{
dndProcessQVnodeRpcMsg
(
pHandle
,
pRsp
,
pEpSet
);
}
}
else
{
dError
(
"rsp:%s not processed since no handle, handle:%p app:%p"
,
TMSG_INFO
(
msgType
),
pRsp
->
handle
,
pRsp
->
ahandle
);
rpcFreeCont
(
pRsp
->
pCont
);
...
...
@@ -110,9 +127,13 @@ static void dndProcessRequest(void *param, SRpcMsg *pReq, SEpSet *pEpSet) {
SMsgHandle
*
pHandle
=
&
pMgmt
->
msgHandles
[
TMSG_INDEX
(
msgType
)];
if
(
pHandle
->
msgFp
!=
NULL
)
{
dTrace
(
"req:%s will be processed by %s, handle:%p app:%p"
,
TMSG_INFO
(
msgType
),
pHandle
->
pWrapper
->
name
,
pReq
->
handle
,
pReq
->
ahandle
);
dndProcessRpcMsg
(
pHandle
->
pWrapper
,
pReq
,
pEpSet
);
if
(
pHandle
->
vgId
==
0
)
{
dTrace
(
"req:%s will be processed by %s, handle:%p app:%p"
,
TMSG_INFO
(
msgType
),
pHandle
->
pWrapper
->
name
,
pReq
->
handle
,
pReq
->
ahandle
);
dndProcessRpcMsg
(
pHandle
->
pWrapper
,
pReq
,
pEpSet
);
}
else
{
dndProcessQVnodeRpcMsg
(
pHandle
,
pReq
,
pEpSet
);
}
}
else
{
dError
(
"req:%s not processed since no handle, handle:%p app:%p"
,
TMSG_INFO
(
msgType
),
pReq
->
handle
,
pReq
->
ahandle
);
SRpcMsg
rspMsg
=
{.
handle
=
pReq
->
handle
,
.
code
=
TSDB_CODE_MSG_NOT_PROCESSED
,
.
ahandle
=
pReq
->
ahandle
};
...
...
@@ -245,17 +266,24 @@ int32_t dndInitMsgHandle(SDnode *pDnode) {
for
(
int32_t
msgIndex
=
0
;
msgIndex
<
TDMT_MAX
;
++
msgIndex
)
{
NodeMsgFp
msgFp
=
pWrapper
->
msgFps
[
msgIndex
];
int32_t
vgId
=
pWrapper
->
msgVgIds
[
msgIndex
];
if
(
msgFp
==
NULL
)
continue
;
SMsgHandle
*
pHandle
=
&
pMgmt
->
msgHandles
[
msgIndex
];
if
(
pHandle
->
msgFp
!=
NULL
)
{
dError
(
"msg:%s has multiple process nodes, prev node:%s
, curr node:%s
"
,
tMsgInfo
[
msgIndex
],
pHandle
->
pWrapper
->
name
,
p
Wrapper
->
name
);
if
(
pHandle
->
msgFp
!=
NULL
&&
pHandle
->
vgId
==
vgId
)
{
dError
(
"msg:%s has multiple process nodes, prev node:%s
:%d, curr node:%s:%d
"
,
tMsgInfo
[
msgIndex
],
pHandle
->
pWrapper
->
name
,
p
Handle
->
pWrapper
->
msgVgIds
[
msgIndex
],
pWrapper
->
name
,
vgId
);
return
-
1
;
}
else
{
dTrace
(
"msg:%s will be processed by %s"
,
tMsgInfo
[
msgIndex
],
pWrapper
->
name
);
pHandle
->
msgFp
=
msgFp
;
pHandle
->
pWrapper
=
pWrapper
;
dTrace
(
"msg:%s will be processed by %s, vgId:%d"
,
tMsgInfo
[
msgIndex
],
pWrapper
->
name
,
vgId
);
if
(
vgId
==
0
)
{
pHandle
->
msgFp
=
msgFp
;
pHandle
->
pWrapper
=
pWrapper
;
}
else
{
pHandle
->
vgId
=
vgId
;
pHandle
->
vgIdMsgFp
=
msgFp
;
pHandle
->
pVgIdWrapper
=
pWrapper
;
}
}
}
}
...
...
source/dnode/mgmt/dnode/src/dmMsg.c
浏览文件 @
4c999f74
...
...
@@ -114,19 +114,19 @@ int32_t dmProcessConfigReq(SDnodeMgmt *pMgmt, SNodeMsg *pMsg) {
void
dmInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{
// Requests handled by DNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_MNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_MNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_QNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_QNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_SNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_SNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_BNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_BNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CONFIG_DNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_NETWORK_TEST
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_MNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_MNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_QNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_QNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_SNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_SNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_BNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_BNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CONFIG_DNODE
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_NETWORK_TEST
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
// Requests handled by MNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_STATUS_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GRANT_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_AUTH_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_STATUS_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GRANT_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_AUTH_RSP
,
(
NodeMsgFp
)
dmProcessMgmtMsg
,
0
);
}
source/dnode/mgmt/mnode/src/mmMsg.c
浏览文件 @
4c999f74
...
...
@@ -75,78 +75,78 @@ int32_t mmProcessAlterReq(SMnodeMgmt *pMgmt, SNodeMsg *pMsg) {
void
mmInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{
// Requests handled by DNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_QNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_QNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_SNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_SNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_BNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_BNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_SYNC_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_COMPACT_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CONFIG_DNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_MNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_QNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_QNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_SNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_SNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_BNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_BNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_SYNC_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_COMPACT_VNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CONFIG_DNODE_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
// Requests handled by MNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CONNECT
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GET_USER_AUTH
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CONFIG_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_QNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_QNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_SNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_SNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_BNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_BNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_USE_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SYNC_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_COMPACT_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_RETRIEVE_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_TABLE_META
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_VGROUP_LIST
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_QUERY
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_CONN
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_HEARTBEAT
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SHOW
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SHOW_RETRIEVE
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_STATUS
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_TRANS
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GRANT
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_AUTH
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SUBSCRIBE
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_MQ_COMMIT_OFFSET
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GET_SUB_EP
,
(
NodeMsgFp
)
mmProcessReadMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CONNECT
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_ACCT
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_USER
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GET_USER_AUTH
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CONFIG_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_DNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_QNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_QNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_SNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_SNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_BNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_BNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_USE_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SYNC_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_COMPACT_DB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_RETRIEVE_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_FUNC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_STB
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_TABLE_META
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_VGROUP_LIST
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_QUERY
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_CONN
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_HEARTBEAT
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SHOW
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SHOW_RETRIEVE
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_STATUS
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_KILL_TRANS
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GRANT
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_AUTH
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_MNODE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_CREATE_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_ALTER_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_DROP_TOPIC
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_SUBSCRIBE
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_MQ_COMMIT_OFFSET
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_MND_GET_SUB_EP
,
(
NodeMsgFp
)
mmProcessReadMsg
,
0
);
// Requests handled by VNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CONN_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_REB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASK_DEPLOY
,
(
NodeMsgFp
)
mmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CONN_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_REB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_STB_RSP
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASK_DEPLOY
,
(
NodeMsgFp
)
mmProcessWriteMsg
,
0
);
}
source/dnode/mgmt/qnode/src/qmMsg.c
浏览文件 @
4c999f74
...
...
@@ -54,4 +54,16 @@ int32_t qmProcessDropReq(SMgmtWrapper *pWrapper, SNodeMsg *pMsg) {
}
}
void
qmInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{}
void
qmInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{
// Requests handled by VNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY
,
(
NodeMsgFp
)
qmProcessQueryMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY_CONTINUE
,
(
NodeMsgFp
)
qmProcessQueryMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH_RSP
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_RES_READY
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASKS_STATUS
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CANCEL_TASK
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_TASK
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SHOW_TABLES
,
(
NodeMsgFp
)
qmProcessFetchMsg
,
1
);
}
source/dnode/mgmt/snode/src/smMsg.c
浏览文件 @
4c999f74
...
...
@@ -56,6 +56,6 @@ int32_t smProcessDropReq(SMgmtWrapper *pWrapper, SNodeMsg *pMsg) {
void
smInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{
// Requests handled by SNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_SND_TASK_DEPLOY
,
(
NodeMsgFp
)
smProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_SND_TASK_EXEC
,
(
NodeMsgFp
)
smProcessExecMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_SND_TASK_DEPLOY
,
(
NodeMsgFp
)
smProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_SND_TASK_EXEC
,
(
NodeMsgFp
)
smProcessExecMsg
,
0
);
}
source/dnode/mgmt/vnode/src/vmMsg.c
浏览文件 @
4c999f74
...
...
@@ -243,42 +243,42 @@ int32_t vmProcessCompactVnodeReq(SVnodesMgmt *pMgmt, SNodeMsg *pMsg) {
void
vmInitMsgHandles
(
SMgmtWrapper
*
pWrapper
)
{
// Requests handled by VNODE
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SUBMIT
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY
,
(
NodeMsgFp
)
vmProcessQueryMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY_CONTINUE
,
(
NodeMsgFp
)
vmProcessQueryMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH_RSP
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_UPDATE_TAG_VAL
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TABLE_META
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TABLES_META
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_CONSUME
,
(
NodeMsgFp
)
vmProcessQueryMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_QUERY
,
(
NodeMsgFp
)
vmProcessQueryMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_CONNECT
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_DISCONNECT
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CUR
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_RES_READY
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASKS_STATUS
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CANCEL_TASK
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_TASK
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SHOW_TABLES
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SHOW_TABLES_FETCH
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CONN
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_REB
,
(
NodeMsgFp
)
vmProcessWriteMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CUR
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CONSUME
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY_HEARTBEAT
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASK_EXEC
,
(
NodeMsgFp
)
vmProcessFetchMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_SYNC_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_COMPACT_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SUBMIT
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY
,
(
NodeMsgFp
)
vmProcessQueryMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY_CONTINUE
,
(
NodeMsgFp
)
vmProcessQueryMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_FETCH_RSP
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_UPDATE_TAG_VAL
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TABLE_META
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TABLES_META
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_CONSUME
,
(
NodeMsgFp
)
vmProcessQueryMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_QUERY
,
(
NodeMsgFp
)
vmProcessQueryMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_CONNECT
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_DISCONNECT
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CUR
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_RES_READY
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASKS_STATUS
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CANCEL_TASK
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_TASK
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_STB
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CREATE_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_ALTER_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_DROP_TABLE
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SHOW_TABLES
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_SHOW_TABLES_FETCH
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CONN
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_REB
,
(
NodeMsgFp
)
vmProcessWriteMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_MQ_SET_CUR
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_CONSUME
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_QUERY_HEARTBEAT
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_VND_TASK_EXEC
,
(
NodeMsgFp
)
vmProcessFetchMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_CREATE_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_ALTER_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_DROP_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_SYNC_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
,
0
);
dndSetMsgHandle
(
pWrapper
,
TDMT_DND_COMPACT_VNODE
,
(
NodeMsgFp
)
vmProcessMgmtMsg
,
0
);
}
source/dnode/mgmt/vnode/src/vmWorker.c
浏览文件 @
4c999f74
...
...
@@ -162,7 +162,7 @@ static int32_t vmPutNodeMsgToQueue(SVnodesMgmt *pMgmt, SNodeMsg *pMsg, EQueueTyp
SVnodeObj
*
pVnode
=
vmAcquireVnode
(
pMgmt
,
pHead
->
vgId
);
if
(
pVnode
==
NULL
)
{
dError
(
"vgId:%d, failed to write msg:%p to queue since %s"
,
pHead
->
vgId
,
pMsg
,
terrstr
());
dError
(
"vgId:%d, failed to write msg:%p to
vnode-
queue since %s"
,
pHead
->
vgId
,
pMsg
,
terrstr
());
return
-
1
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录