Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
9624073d
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
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看板
提交
9624073d
编写于
9月 23, 2022
作者:
H
Hongze Cheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
refact more code
上级
d789fe6a
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
39 addition
and
25 deletion
+39
-25
source/dnode/vnode/src/tsdb/tsdbCommit.c
source/dnode/vnode/src/tsdb/tsdbCommit.c
+39
-25
未找到文件。
source/dnode/vnode/src/tsdb/tsdbCommit.c
浏览文件 @
9624073d
...
...
@@ -139,7 +139,7 @@ int32_t tsdbBegin(STsdb *pTsdb) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -180,7 +180,7 @@ int32_t tsdbCommit(STsdb *pTsdb) {
_exit:
if
(
code
)
{
tsdbEndCommit
(
&
commith
,
code
);
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -222,7 +222,7 @@ static int32_t tsdbCommitDelStart(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d, %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d, %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
else
{
tsdbDebug
(
"vgId:%d, commit del start"
,
TD_VID
(
pTsdb
->
pVnode
));
}
...
...
@@ -280,7 +280,8 @@ static int32_t tsdbCommitTableDel(SCommitter *pCommitter, STbData *pTbData, SDel
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d, %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d, %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -313,7 +314,8 @@ static int32_t tsdbCommitDelEnd(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d, %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d, %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -464,7 +466,8 @@ static int32_t tsdbOpenCommitIter(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -547,7 +550,7 @@ static int32_t tsdbCommitFileDataStart(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -599,7 +602,7 @@ int32_t tsdbWriteDataBlock(SDataFWriter *pWriter, SBlockData *pBlockData, SMapDa
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pWriter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pWriter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -642,7 +645,7 @@ int32_t tsdbWriteSttBlock(SDataFWriter *pWriter, SBlockData *pBlockData, SArray
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pWriter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pWriter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -678,7 +681,8 @@ static int32_t tsdbCommitFileDataEnd(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -703,7 +707,8 @@ static int32_t tsdbMoveCommitData(SCommitter *pCommitter, TABLEID toTable) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -729,7 +734,7 @@ static int32_t tsdbCommitFileData(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbDataFReaderClose
(
&
pCommitter
->
dReader
.
pReader
);
tsdbDataFWriterClose
(
&
pCommitter
->
dWriter
.
pWriter
,
0
);
}
...
...
@@ -767,7 +772,7 @@ static int32_t tsdbStartCommit(STsdb *pTsdb, SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -820,7 +825,8 @@ static int32_t tsdbCommitDataStart(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -874,7 +880,7 @@ static int32_t tsdbCommitData(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -960,7 +966,7 @@ static int32_t tsdbCommitDel(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
else
{
tsdbDebug
(
"vgId:%d commit del done, nDel:%"
PRId64
,
TD_VID
(
pTsdb
->
pVnode
),
pMemTable
->
nDel
);
}
...
...
@@ -1000,7 +1006,7 @@ static int32_t tsdbEndCommit(SCommitter *pCommitter, int32_t eno) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s fail
ed at
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail
at line
%d since %s"
,
TD_VID
(
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
else
{
tsdbInfo
(
"vgId:%d tsdb end commit"
,
TD_VID
(
pTsdb
->
pVnode
));
}
...
...
@@ -1094,7 +1100,8 @@ static int32_t tsdbNextCommitRow(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1141,7 +1148,8 @@ static int32_t tsdbCommitAheadBlock(SCommitter *pCommitter, SDataBlk *pDataBlk)
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1227,7 +1235,8 @@ static int32_t tsdbCommitMergeBlock(SCommitter *pCommitter, SDataBlk *pDataBlk)
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1301,7 +1310,8 @@ static int32_t tsdbMergeTableData(SCommitter *pCommitter, TABLEID id) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1328,7 +1338,8 @@ static int32_t tsdbInitLastBlockIfNeed(SCommitter *pCommitter, TABLEID id) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1357,7 +1368,8 @@ static int32_t tsdbAppendLastBlock(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1426,7 +1438,8 @@ static int32_t tsdbCommitTableData(SCommitter *pCommitter, TABLEID id) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
...
...
@@ -1488,7 +1501,8 @@ static int32_t tsdbCommitFileDataImpl(SCommitter *pCommitter) {
_exit:
if
(
code
)
{
tsdbError
(
"vgId:%d %s failed at %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
tsdbError
(
"vgId:%d %s fail at line %d since %s"
,
TD_VID
(
pCommitter
->
pTsdb
->
pVnode
),
__func__
,
lino
,
tstrerror
(
code
));
}
return
code
;
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录