Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
ad965dbc
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1184
Star
22015
Fork
4786
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
ad965dbc
编写于
1月 04, 2022
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
invalid release
上级
6ae9a421
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
21 addition
and
15 deletion
+21
-15
source/dnode/mnode/impl/src/mndBnode.c
source/dnode/mnode/impl/src/mndBnode.c
+7
-5
source/dnode/mnode/impl/src/mndQnode.c
source/dnode/mnode/impl/src/mndQnode.c
+7
-5
source/dnode/mnode/impl/src/mndSnode.c
source/dnode/mnode/impl/src/mndSnode.c
+7
-5
未找到文件。
source/dnode/mnode/impl/src/mndBnode.c
浏览文件 @
ad965dbc
...
...
@@ -26,7 +26,7 @@ static SSdbRaw *mndBnodeActionEncode(SBnodeObj *pObj);
static
SSdbRow
*
mndBnodeActionDecode
(
SSdbRaw
*
pRaw
);
static
int32_t
mndBnodeActionInsert
(
SSdb
*
pSdb
,
SBnodeObj
*
pObj
);
static
int32_t
mndBnodeActionDelete
(
SSdb
*
pSdb
,
SBnodeObj
*
pObj
);
static
int32_t
mndBnodeActionUpdate
(
SSdb
*
pSdb
,
SBnodeObj
*
pOld
Bnode
,
SBnodeObj
*
pNewBnode
);
static
int32_t
mndBnodeActionUpdate
(
SSdb
*
pSdb
,
SBnodeObj
*
pOld
,
SBnodeObj
*
pNew
);
static
int32_t
mndProcessCreateBnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessDropBnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessCreateBnodeRsp
(
SMnodeMsg
*
pMsg
);
...
...
@@ -155,9 +155,9 @@ static int32_t mndBnodeActionDelete(SSdb *pSdb, SBnodeObj *pObj) {
return
0
;
}
static
int32_t
mndBnodeActionUpdate
(
SSdb
*
pSdb
,
SBnodeObj
*
pOld
Bnode
,
SBnodeObj
*
pNewBnode
)
{
mTrace
(
"bnode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
Bnode
->
id
,
pOldBnode
,
pNewBnode
);
pOld
Bnode
->
updateTime
=
pNewBnode
->
updateTime
;
static
int32_t
mndBnodeActionUpdate
(
SSdb
*
pSdb
,
SBnodeObj
*
pOld
,
SBnodeObj
*
pNew
)
{
mTrace
(
"bnode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
->
id
,
pOld
,
pNew
);
pOld
->
updateTime
=
pNew
->
updateTime
;
return
0
;
}
...
...
@@ -251,6 +251,7 @@ static int32_t mndProcessCreateBnodeReq(SMnodeMsg *pMsg) {
SBnodeObj
*
pObj
=
mndAcquireBnode
(
pMnode
,
pCreate
->
dnodeId
);
if
(
pObj
!=
NULL
)
{
mError
(
"bnode:%d, bnode already exist"
,
pObj
->
id
);
terrno
=
TSDB_CODE_MND_BNODE_ALREADY_EXIST
;
mndReleaseBnode
(
pMnode
,
pObj
);
return
-
1
;
}
...
...
@@ -370,11 +371,12 @@ static int32_t mndProcessDropBnodeReq(SMnodeMsg *pMsg) {
int32_t
code
=
mndDropBnode
(
pMnode
,
pMsg
,
pObj
);
if
(
code
!=
0
)
{
sdbRelease
(
pMnode
->
pSdb
,
pObj
);
mError
(
"bnode:%d, failed to drop since %s"
,
pMnode
->
dnodeId
,
terrstr
());
return
-
1
;
}
sdbRelease
(
pMnode
->
pSdb
,
p
Mnode
);
sdbRelease
(
pMnode
->
pSdb
,
p
Obj
);
return
TSDB_CODE_MND_ACTION_IN_PROGRESS
;
}
...
...
source/dnode/mnode/impl/src/mndQnode.c
浏览文件 @
ad965dbc
...
...
@@ -26,7 +26,7 @@ static SSdbRaw *mndQnodeActionEncode(SQnodeObj *pObj);
static
SSdbRow
*
mndQnodeActionDecode
(
SSdbRaw
*
pRaw
);
static
int32_t
mndQnodeActionInsert
(
SSdb
*
pSdb
,
SQnodeObj
*
pObj
);
static
int32_t
mndQnodeActionDelete
(
SSdb
*
pSdb
,
SQnodeObj
*
pObj
);
static
int32_t
mndQnodeActionUpdate
(
SSdb
*
pSdb
,
SQnodeObj
*
pOld
Qnode
,
SQnodeObj
*
pNewQnode
);
static
int32_t
mndQnodeActionUpdate
(
SSdb
*
pSdb
,
SQnodeObj
*
pOld
,
SQnodeObj
*
pNew
);
static
int32_t
mndProcessCreateQnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessDropQnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessCreateQnodeRsp
(
SMnodeMsg
*
pMsg
);
...
...
@@ -155,9 +155,9 @@ static int32_t mndQnodeActionDelete(SSdb *pSdb, SQnodeObj *pObj) {
return
0
;
}
static
int32_t
mndQnodeActionUpdate
(
SSdb
*
pSdb
,
SQnodeObj
*
pOld
Qnode
,
SQnodeObj
*
pNewQnode
)
{
mTrace
(
"qnode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
Qnode
->
id
,
pOldQnode
,
pNewQnode
);
pOld
Qnode
->
updateTime
=
pNewQnode
->
updateTime
;
static
int32_t
mndQnodeActionUpdate
(
SSdb
*
pSdb
,
SQnodeObj
*
pOld
,
SQnodeObj
*
pNew
)
{
mTrace
(
"qnode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
->
id
,
pOld
,
pNew
);
pOld
->
updateTime
=
pNew
->
updateTime
;
return
0
;
}
...
...
@@ -251,6 +251,7 @@ static int32_t mndProcessCreateQnodeReq(SMnodeMsg *pMsg) {
SQnodeObj
*
pObj
=
mndAcquireQnode
(
pMnode
,
pCreate
->
dnodeId
);
if
(
pObj
!=
NULL
)
{
mError
(
"qnode:%d, qnode already exist"
,
pObj
->
id
);
terrno
=
TSDB_CODE_MND_QNODE_ALREADY_EXIST
;
mndReleaseQnode
(
pMnode
,
pObj
);
return
-
1
;
}
...
...
@@ -370,11 +371,12 @@ static int32_t mndProcessDropQnodeReq(SMnodeMsg *pMsg) {
int32_t
code
=
mndDropQnode
(
pMnode
,
pMsg
,
pObj
);
if
(
code
!=
0
)
{
sdbRelease
(
pMnode
->
pSdb
,
pObj
);
mError
(
"qnode:%d, failed to drop since %s"
,
pMnode
->
dnodeId
,
terrstr
());
return
-
1
;
}
sdbRelease
(
pMnode
->
pSdb
,
p
Mnode
);
sdbRelease
(
pMnode
->
pSdb
,
p
Obj
);
return
TSDB_CODE_MND_ACTION_IN_PROGRESS
;
}
...
...
source/dnode/mnode/impl/src/mndSnode.c
浏览文件 @
ad965dbc
...
...
@@ -26,7 +26,7 @@ static SSdbRaw *mndSnodeActionEncode(SSnodeObj *pObj);
static
SSdbRow
*
mndSnodeActionDecode
(
SSdbRaw
*
pRaw
);
static
int32_t
mndSnodeActionInsert
(
SSdb
*
pSdb
,
SSnodeObj
*
pObj
);
static
int32_t
mndSnodeActionDelete
(
SSdb
*
pSdb
,
SSnodeObj
*
pObj
);
static
int32_t
mndSnodeActionUpdate
(
SSdb
*
pSdb
,
SSnodeObj
*
pOld
Snode
,
SSnodeObj
*
pNewSnode
);
static
int32_t
mndSnodeActionUpdate
(
SSdb
*
pSdb
,
SSnodeObj
*
pOld
,
SSnodeObj
*
pNew
);
static
int32_t
mndProcessCreateSnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessDropSnodeReq
(
SMnodeMsg
*
pMsg
);
static
int32_t
mndProcessCreateSnodeRsp
(
SMnodeMsg
*
pMsg
);
...
...
@@ -155,9 +155,9 @@ static int32_t mndSnodeActionDelete(SSdb *pSdb, SSnodeObj *pObj) {
return
0
;
}
static
int32_t
mndSnodeActionUpdate
(
SSdb
*
pSdb
,
SSnodeObj
*
pOld
Snode
,
SSnodeObj
*
pNewSnode
)
{
mTrace
(
"snode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
Snode
->
id
,
pOldSnode
,
pNewSnode
);
pOld
Snode
->
updateTime
=
pNewSnode
->
updateTime
;
static
int32_t
mndSnodeActionUpdate
(
SSdb
*
pSdb
,
SSnodeObj
*
pOld
,
SSnodeObj
*
pNew
)
{
mTrace
(
"snode:%d, perform update action, old_row:%p new_row:%p"
,
pOld
->
id
,
pOld
,
pNew
);
pOld
->
updateTime
=
pNew
->
updateTime
;
return
0
;
}
...
...
@@ -251,6 +251,7 @@ static int32_t mndProcessCreateSnodeReq(SMnodeMsg *pMsg) {
SSnodeObj
*
pObj
=
mndAcquireSnode
(
pMnode
,
pCreate
->
dnodeId
);
if
(
pObj
!=
NULL
)
{
mError
(
"snode:%d, snode already exist"
,
pObj
->
id
);
terrno
=
TSDB_CODE_MND_SNODE_ALREADY_EXIST
;
mndReleaseSnode
(
pMnode
,
pObj
);
return
-
1
;
}
...
...
@@ -370,11 +371,12 @@ static int32_t mndProcessDropSnodeReq(SMnodeMsg *pMsg) {
int32_t
code
=
mndDropSnode
(
pMnode
,
pMsg
,
pObj
);
if
(
code
!=
0
)
{
sdbRelease
(
pMnode
->
pSdb
,
pObj
);
mError
(
"snode:%d, failed to drop since %s"
,
pMnode
->
dnodeId
,
terrstr
());
return
-
1
;
}
sdbRelease
(
pMnode
->
pSdb
,
p
Mnode
);
sdbRelease
(
pMnode
->
pSdb
,
p
Obj
);
return
TSDB_CODE_MND_ACTION_IN_PROGRESS
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录