Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
a8efcbd7
T
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
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看板
提交
a8efcbd7
编写于
12月 14, 2020
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
TD-1843
上级
3c1daaf9
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
23 addition
and
8 deletion
+23
-8
src/cq/src/cqMain.c
src/cq/src/cqMain.c
+1
-1
src/dnode/src/dnodeStep.c
src/dnode/src/dnodeStep.c
+1
-1
src/dnode/src/dnodeVnodes.c
src/dnode/src/dnodeVnodes.c
+12
-3
src/mnode/src/mnodeSdb.c
src/mnode/src/mnodeSdb.c
+6
-0
src/rpc/src/rpcMain.c
src/rpc/src/rpcMain.c
+1
-1
src/util/src/tqueue.c
src/util/src/tqueue.c
+2
-2
未找到文件。
src/cq/src/cqMain.c
浏览文件 @
a8efcbd7
...
...
@@ -298,7 +298,7 @@ static void cqCreateStream(SCqContext *pContext, SCqObj *pObj) {
if
(
pObj
->
pStream
)
{
tscSetStreamDestTable
(
pObj
->
pStream
,
pObj
->
dstTable
);
pContext
->
num
++
;
cDebug
(
"vgId:%d, id:%d CQ:%s is open
n
ed"
,
pContext
->
vgId
,
pObj
->
tid
,
pObj
->
sqlStr
);
cDebug
(
"vgId:%d, id:%d CQ:%s is opened"
,
pContext
->
vgId
,
pObj
->
tid
,
pObj
->
sqlStr
);
}
else
{
cError
(
"vgId:%d, id:%d CQ:%s, failed to open"
,
pContext
->
vgId
,
pObj
->
tid
,
pObj
->
sqlStr
);
}
...
...
src/dnode/src/dnodeStep.c
浏览文件 @
a8efcbd7
...
...
@@ -63,7 +63,7 @@ int32_t dnodeStepInit(SStep *pSteps, int32_t stepSize) {
}
dInfo
(
"step:%s is initialized"
,
pStep
->
name
);
dnodeReportStep
(
pStep
->
name
,
"Initialization complete"
,
step
+
1
>=
stepSize
);
dnodeReportStep
(
pStep
->
name
,
"Initialization complete"
,
0
);
}
return
0
;
...
...
src/dnode/src/dnodeVnodes.c
浏览文件 @
a8efcbd7
...
...
@@ -33,6 +33,8 @@ typedef struct {
extern
void
*
tsDnodeTmr
;
static
void
*
tsStatusTimer
=
NULL
;
static
uint32_t
tsRebootTime
=
0
;
static
int32_t
tsOpenVnodes
=
0
;
static
int32_t
tsTotalVnodes
=
0
;
static
void
dnodeSendStatusMsg
(
void
*
handle
,
void
*
tmrId
);
static
void
dnodeProcessStatusRsp
(
SRpcMsg
*
pMsg
);
...
...
@@ -84,21 +86,27 @@ static int32_t dnodeGetVnodeList(int32_t vnodeList[], int32_t *numOfVnodes) {
static
void
*
dnodeOpenVnode
(
void
*
param
)
{
SOpenVnodeThread
*
pThread
=
param
;
char
stepDesc
[
TSDB_STEP_DESC_LEN
]
=
{
0
};
dDebug
(
"thread:%d, start to open %d vnodes"
,
pThread
->
threadIndex
,
pThread
->
vnodeNum
);
for
(
int32_t
v
=
0
;
v
<
pThread
->
vnodeNum
;
++
v
)
{
int32_t
vgId
=
pThread
->
vnodeList
[
v
];
snprintf
(
stepDesc
,
TSDB_STEP_DESC_LEN
,
"vgId:%d, start to restore, %d of %d have been opened"
,
vgId
,
tsOpenVnodes
,
tsTotalVnodes
);
dnodeReportStep
(
"open-vnodes"
,
stepDesc
,
0
);
if
(
vnodeOpen
(
vgId
)
<
0
)
{
dError
(
"vgId:%d, failed to open vnode by thread:%d"
,
vgId
,
pThread
->
threadIndex
);
pThread
->
failed
++
;
}
else
{
dDebug
(
"vgId:%d, is open
n
ed by thread:%d"
,
vgId
,
pThread
->
threadIndex
);
dDebug
(
"vgId:%d, is opened by thread:%d"
,
vgId
,
pThread
->
threadIndex
);
pThread
->
opened
++
;
}
atomic_add_fetch_32
(
&
tsOpenVnodes
,
1
);
}
dDebug
(
"thread:%d, total vnodes:%d, open
n
ed:%d failed:%d"
,
pThread
->
threadIndex
,
pThread
->
vnodeNum
,
pThread
->
opened
,
dDebug
(
"thread:%d, total vnodes:%d, opened:%d failed:%d"
,
pThread
->
threadIndex
,
pThread
->
vnodeNum
,
pThread
->
opened
,
pThread
->
failed
);
return
NULL
;
}
...
...
@@ -107,6 +115,7 @@ int32_t dnodeInitVnodes() {
int32_t
vnodeList
[
TSDB_MAX_VNODES
]
=
{
0
};
int32_t
numOfVnodes
=
0
;
int32_t
status
=
dnodeGetVnodeList
(
vnodeList
,
&
numOfVnodes
);
tsTotalVnodes
=
numOfVnodes
;
if
(
status
!=
TSDB_CODE_SUCCESS
)
{
dInfo
(
"get dnode list failed"
);
...
...
@@ -156,7 +165,7 @@ int32_t dnodeInitVnodes() {
}
free
(
threads
);
dInfo
(
"there are total vnodes:%d, open
n
ed:%d"
,
numOfVnodes
,
openVnodes
);
dInfo
(
"there are total vnodes:%d, opened:%d"
,
numOfVnodes
,
openVnodes
);
if
(
failedVnodes
!=
0
)
{
dError
(
"there are total vnodes:%d, failed:%d"
,
numOfVnodes
,
failedVnodes
);
...
...
src/mnode/src/mnodeSdb.c
浏览文件 @
a8efcbd7
...
...
@@ -633,6 +633,12 @@ static int32_t sdbProcessWrite(void *wparam, void *hparam, int32_t qtype, void *
SSdbTable
*
pTable
=
sdbGetTableFromId
(
tableId
);
assert
(
pTable
!=
NULL
);
if
(
!
mnodeIsRunning
()
&&
tsSdbMgmt
.
version
%
100000
==
0
)
{
char
stepDesc
[
TSDB_STEP_DESC_LEN
]
=
{
0
};
snprintf
(
stepDesc
,
TSDB_STEP_DESC_LEN
,
"%"
PRIu64
" rows have been restored"
,
tsSdbMgmt
.
version
);
dnodeReportStep
(
"mnode-sdb"
,
stepDesc
,
0
);
}
if
(
qtype
==
TAOS_QTYPE_QUERY
)
return
sdbPerformDeleteAction
(
pHead
,
pTable
);
pthread_mutex_lock
(
&
tsSdbMgmt
.
mutex
);
...
...
src/rpc/src/rpcMain.c
浏览文件 @
a8efcbd7
...
...
@@ -313,7 +313,7 @@ void *rpcOpen(const SRpcInit *pInit) {
return
NULL
;
}
tDebug
(
"%s rpc is open
n
ed, threads:%d sessions:%d"
,
pRpc
->
label
,
pRpc
->
numOfThreads
,
pInit
->
sessions
);
tDebug
(
"%s rpc is opened, threads:%d sessions:%d"
,
pRpc
->
label
,
pRpc
->
numOfThreads
,
pInit
->
sessions
);
return
pRpc
;
}
...
...
src/util/src/tqueue.c
浏览文件 @
a8efcbd7
...
...
@@ -61,7 +61,7 @@ taos_queue taosOpenQueue() {
pthread_mutex_init
(
&
queue
->
mutex
,
NULL
);
uTrace
(
"queue:%p is open
n
ed"
,
queue
);
uTrace
(
"queue:%p is opened"
,
queue
);
return
queue
;
}
...
...
@@ -230,7 +230,7 @@ taos_qset taosOpenQset() {
pthread_mutex_init
(
&
qset
->
mutex
,
NULL
);
tsem_init
(
&
qset
->
sem
,
0
,
0
);
uTrace
(
"qset:%p is open
n
ed"
,
qset
);
uTrace
(
"qset:%p is opened"
,
qset
);
return
qset
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录