Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
buyaopa
TDengine
提交
6b1f57a1
T
TDengine
项目概览
buyaopa
/
TDengine
与 Fork 源项目一致
Fork自
taosdata / TDengine
通知
3
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
T
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
6b1f57a1
编写于
6月 28, 2020
作者:
S
Shengliang Guan
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[TD-526]
上级
50e91af9
变更
16
隐藏空白更改
内联
并排
Showing
16 changed file
with
95 addition
and
93 deletion
+95
-93
src/dnode/inc/dnodeInt.h
src/dnode/inc/dnodeInt.h
+4
-4
src/mnode/inc/mnodeInt.h
src/mnode/inc/mnodeInt.h
+8
-8
src/plugins/http/inc/httpLog.h
src/plugins/http/inc/httpLog.h
+4
-4
src/plugins/monitor/src/monitorMain.c
src/plugins/monitor/src/monitorMain.c
+4
-4
src/plugins/mqtt/inc/mqttLog.h
src/plugins/mqtt/inc/mqttLog.h
+4
-4
src/query/inc/queryLog.h
src/query/inc/queryLog.h
+4
-4
src/tsdb/inc/tsdbMain.h
src/tsdb/inc/tsdbMain.h
+6
-4
src/tsdb/src/tsdbBuffer.c
src/tsdb/src/tsdbBuffer.c
+3
-3
src/tsdb/src/tsdbFile.c
src/tsdb/src/tsdbFile.c
+1
-1
src/tsdb/src/tsdbMain.c
src/tsdb/src/tsdbMain.c
+10
-10
src/tsdb/src/tsdbMemTable.c
src/tsdb/src/tsdbMemTable.c
+4
-4
src/tsdb/src/tsdbMeta.c
src/tsdb/src/tsdbMeta.c
+13
-13
src/tsdb/src/tsdbRWHelper.c
src/tsdb/src/tsdbRWHelper.c
+4
-4
src/tsdb/src/tsdbRead.c
src/tsdb/src/tsdbRead.c
+18
-18
src/vnode/inc/vnodeInt.h
src/vnode/inc/vnodeInt.h
+4
-4
src/wal/src/walMain.c
src/wal/src/walMain.c
+4
-4
未找到文件。
src/dnode/inc/dnodeInt.h
浏览文件 @
6b1f57a1
...
...
@@ -24,10 +24,10 @@ extern "C" {
extern
int32_t
dDebugFlag
;
#define dFatal(...) { if (dDebugFlag & DEBUG_FATAL) { taosPrintLog("DND FATAL ",
dDebugFlag
, __VA_ARGS__); }}
#define dError(...) { if (dDebugFlag & DEBUG_ERROR) { taosPrintLog("DND ERROR ",
dDebugFlag
, __VA_ARGS__); }}
#define dWarn(...) { if (dDebugFlag & DEBUG_WARN) { taosPrintLog("DND WARN ",
dDebugFlag
, __VA_ARGS__); }}
#define dInfo(...) { if (dDebugFlag & DEBUG_INFO) { taosPrintLog("DND INFO ",
dDebugFlag
, __VA_ARGS__); }}
#define dFatal(...) { if (dDebugFlag & DEBUG_FATAL) { taosPrintLog("DND FATAL ",
255
, __VA_ARGS__); }}
#define dError(...) { if (dDebugFlag & DEBUG_ERROR) { taosPrintLog("DND ERROR ",
255
, __VA_ARGS__); }}
#define dWarn(...) { if (dDebugFlag & DEBUG_WARN) { taosPrintLog("DND WARN ",
255
, __VA_ARGS__); }}
#define dInfo(...) { if (dDebugFlag & DEBUG_INFO) { taosPrintLog("DND INFO ",
255
, __VA_ARGS__); }}
#define dDebug(...) { if (dDebugFlag & DEBUG_DEBUG) { taosPrintLog("DND DEBUG ", dDebugFlag, __VA_ARGS__); }}
#define dTrace(...) { if (dDebugFlag & DEBUG_TRACE) { taosPrintLog("DND TRACE ", dDebugFlag, __VA_ARGS__); }}
...
...
src/mnode/inc/mnodeInt.h
浏览文件 @
6b1f57a1
...
...
@@ -27,17 +27,17 @@ extern int32_t mDebugFlag;
extern
int32_t
sdbDebugFlag
;
// mnode log function
#define mFatal(...) { if (mDebugFlag & DEBUG_FATAL) { taosPrintLog("MND FATAL ",
mDebugFlag
, __VA_ARGS__); }}
#define mError(...) { if (mDebugFlag & DEBUG_ERROR) { taosPrintLog("MND ERROR ",
mDebugFlag
, __VA_ARGS__); }}
#define mWarn(...) { if (mDebugFlag & DEBUG_WARN) { taosPrintLog("MND WARN ",
mDebugFlag
, __VA_ARGS__); }}
#define mInfo(...) { if (mDebugFlag & DEBUG_INFO) { taosPrintLog("MND INFO ",
mDebugFlag
, __VA_ARGS__); }}
#define mFatal(...) { if (mDebugFlag & DEBUG_FATAL) { taosPrintLog("MND FATAL ",
255
, __VA_ARGS__); }}
#define mError(...) { if (mDebugFlag & DEBUG_ERROR) { taosPrintLog("MND ERROR ",
255
, __VA_ARGS__); }}
#define mWarn(...) { if (mDebugFlag & DEBUG_WARN) { taosPrintLog("MND WARN ",
255
, __VA_ARGS__); }}
#define mInfo(...) { if (mDebugFlag & DEBUG_INFO) { taosPrintLog("MND INFO ",
255
, __VA_ARGS__); }}
#define mDebug(...) { if (mDebugFlag & DEBUG_DEBUG) { taosPrintLog("MND DEBUG ", mDebugFlag, __VA_ARGS__); }}
#define mTrace(...) { if (mDebugFlag & DEBUG_TRACE) { taosPrintLog("MND TRACE ", mDebugFlag, __VA_ARGS__); }}
#define sdbFatal(...) { if (sdbDebugFlag & DEBUG_FATAL) { taosPrintLog("SDB FATAL ",
sdbDebugFlag
, __VA_ARGS__); }}
#define sdbError(...) { if (sdbDebugFlag & DEBUG_ERROR) { taosPrintLog("SDB ERROR ",
sdbDebugFlag
, __VA_ARGS__); }}
#define sdbWarn(...) { if (sdbDebugFlag & DEBUG_WARN) { taosPrintLog("SDB WARN ",
sdbDebugFlag
, __VA_ARGS__); }}
#define sdbInfo(...) { if (sdbDebugFlag & DEBUG_INFO) { taosPrintLog("SDB INFO ",
sdbDebugFlag
, __VA_ARGS__); }}
#define sdbFatal(...) { if (sdbDebugFlag & DEBUG_FATAL) { taosPrintLog("SDB FATAL ",
255
, __VA_ARGS__); }}
#define sdbError(...) { if (sdbDebugFlag & DEBUG_ERROR) { taosPrintLog("SDB ERROR ",
255
, __VA_ARGS__); }}
#define sdbWarn(...) { if (sdbDebugFlag & DEBUG_WARN) { taosPrintLog("SDB WARN ",
255
, __VA_ARGS__); }}
#define sdbInfo(...) { if (sdbDebugFlag & DEBUG_INFO) { taosPrintLog("SDB INFO ",
255
, __VA_ARGS__); }}
#define sdbDebug(...) { if (sdbDebugFlag & DEBUG_DEBUG) { taosPrintLog("SDB DEBUG ", sdbDebugFlag, __VA_ARGS__); }}
#define sdbTrace(...) { if (sdbDebugFlag & DEBUG_TRACE) { taosPrintLog("SDB TRACE ", sdbDebugFlag, __VA_ARGS__); }}
...
...
src/plugins/http/inc/httpLog.h
浏览文件 @
6b1f57a1
...
...
@@ -20,10 +20,10 @@
extern
int32_t
httpDebugFlag
;
#define httpFatal(...) { if (httpDebugFlag & DEBUG_FATAL) { taosPrintLog("HTP FATAL ",
httpDebugFlag
, __VA_ARGS__); }}
#define httpError(...) { if (httpDebugFlag & DEBUG_ERROR) { taosPrintLog("HTP ERROR ",
httpDebugFlag
, __VA_ARGS__); }}
#define httpWarn(...) { if (httpDebugFlag & DEBUG_WARN) { taosPrintLog("HTP WARN ",
httpDebugFlag
, __VA_ARGS__); }}
#define httpInfo(...) { if (httpDebugFlag & DEBUG_INFO) { taosPrintLog("HTP INFO ",
httpDebugFlag
, __VA_ARGS__); }}
#define httpFatal(...) { if (httpDebugFlag & DEBUG_FATAL) { taosPrintLog("HTP FATAL ",
255
, __VA_ARGS__); }}
#define httpError(...) { if (httpDebugFlag & DEBUG_ERROR) { taosPrintLog("HTP ERROR ",
255
, __VA_ARGS__); }}
#define httpWarn(...) { if (httpDebugFlag & DEBUG_WARN) { taosPrintLog("HTP WARN ",
255
, __VA_ARGS__); }}
#define httpInfo(...) { if (httpDebugFlag & DEBUG_INFO) { taosPrintLog("HTP INFO ",
255
, __VA_ARGS__); }}
#define httpDebug(...) { if (httpDebugFlag & DEBUG_DEBUG) { taosPrintLog("HTP DEBUG ", httpDebugFlag, __VA_ARGS__); }}
#define httpTrace(...) { if (httpDebugFlag & DEBUG_TRACE) { taosPrintLog("HTP TRACE ", httpDebugFlag, __VA_ARGS__); }}
...
...
src/plugins/monitor/src/monitorMain.c
浏览文件 @
6b1f57a1
...
...
@@ -28,10 +28,10 @@
#include "monitor.h"
#define monitorFatal(...) { if (monitorDebugFlag & DEBUG_FATAL) { taosPrintLog("MON FATAL ",
monitorDebugFlag
, __VA_ARGS__); }}
#define monitorError(...) { if (monitorDebugFlag & DEBUG_ERROR) { taosPrintLog("MON ERROR ",
monitorDebugFlag
, __VA_ARGS__); }}
#define monitorWarn(...) { if (monitorDebugFlag & DEBUG_WARN) { taosPrintLog("MON WARN ",
monitorDebugFlag
, __VA_ARGS__); }}
#define monitorInfo(...) { if (monitorDebugFlag & DEBUG_INFO) { taosPrintLog("MON INFO ",
monitorDebugFlag
, __VA_ARGS__); }}
#define monitorFatal(...) { if (monitorDebugFlag & DEBUG_FATAL) { taosPrintLog("MON FATAL ",
255
, __VA_ARGS__); }}
#define monitorError(...) { if (monitorDebugFlag & DEBUG_ERROR) { taosPrintLog("MON ERROR ",
255
, __VA_ARGS__); }}
#define monitorWarn(...) { if (monitorDebugFlag & DEBUG_WARN) { taosPrintLog("MON WARN ",
255
, __VA_ARGS__); }}
#define monitorInfo(...) { if (monitorDebugFlag & DEBUG_INFO) { taosPrintLog("MON INFO ",
255
, __VA_ARGS__); }}
#define monitorDebug(...) { if (monitorDebugFlag & DEBUG_DEBUG) { taosPrintLog("MON DEBUG ", monitorDebugFlag, __VA_ARGS__); }}
#define monitorTrace(...) { if (monitorDebugFlag & DEBUG_TRACE) { taosPrintLog("MON TRACE ", monitorDebugFlag, __VA_ARGS__); }}
...
...
src/plugins/mqtt/inc/mqttLog.h
浏览文件 @
6b1f57a1
...
...
@@ -20,10 +20,10 @@
extern
int32_t
mqttDebugFlag
;
#define mqttFatal(...) { if (mqttDebugFlag & DEBUG_FATAL) { taosPrintLog("MQT FATAL ",
mqttDebugFlag
, __VA_ARGS__); }}
#define mqttError(...) { if (mqttDebugFlag & DEBUG_ERROR) { taosPrintLog("MQT ERROR ",
mqttDebugFlag
, __VA_ARGS__); }}
#define mqttWarn(...) { if (mqttDebugFlag & DEBUG_WARN) { taosPrintLog("MQT WARN ",
mqttDebugFlag
, __VA_ARGS__); }}
#define mqttInfo(...) { if (mqttDebugFlag & DEBUG_INFO) { taosPrintLog("MQT INFO ",
mqttDebugFlag
, __VA_ARGS__); }}
#define mqttFatal(...) { if (mqttDebugFlag & DEBUG_FATAL) { taosPrintLog("MQT FATAL ",
255
, __VA_ARGS__); }}
#define mqttError(...) { if (mqttDebugFlag & DEBUG_ERROR) { taosPrintLog("MQT ERROR ",
255
, __VA_ARGS__); }}
#define mqttWarn(...) { if (mqttDebugFlag & DEBUG_WARN) { taosPrintLog("MQT WARN ",
255
, __VA_ARGS__); }}
#define mqttInfo(...) { if (mqttDebugFlag & DEBUG_INFO) { taosPrintLog("MQT INFO ",
255
, __VA_ARGS__); }}
#define mqttDebug(...) { if (mqttDebugFlag & DEBUG_DEBUG) { taosPrintLog("MQT DEBUG ", mqttDebugFlag, __VA_ARGS__); }}
#define mqttTrace(...) { if (mqttDebugFlag & DEBUG_TRACE) { taosPrintLog("MQT TRACE ", mqttDebugFlag, __VA_ARGS__); }}
...
...
src/query/inc/queryLog.h
浏览文件 @
6b1f57a1
...
...
@@ -25,10 +25,10 @@ extern "C" {
extern
int32_t
qDebugFlag
;
extern
int32_t
tscEmbedded
;
#define qFatal(...) { if (qDebugFlag & DEBUG_FATAL) { taosPrintLog("QRY FATAL ",
qDebugFlag
, __VA_ARGS__); }}
#define qError(...) { if (qDebugFlag & DEBUG_ERROR) { taosPrintLog("QRY ERROR ",
qDebugFlag
, __VA_ARGS__); }}
#define qWarn(...) { if (qDebugFlag & DEBUG_WARN) { taosPrintLog("QRY WARN ",
qDebugFlag
, __VA_ARGS__); }}
#define qInfo(...) { if (qDebugFlag & DEBUG_INFO) { taosPrintLog("QRY INFO ",
qDebugFlag
, __VA_ARGS__); }}
#define qFatal(...) { if (qDebugFlag & DEBUG_FATAL) { taosPrintLog("QRY FATAL ",
255
, __VA_ARGS__); }}
#define qError(...) { if (qDebugFlag & DEBUG_ERROR) { taosPrintLog("QRY ERROR ",
255
, __VA_ARGS__); }}
#define qWarn(...) { if (qDebugFlag & DEBUG_WARN) { taosPrintLog("QRY WARN ",
255
, __VA_ARGS__); }}
#define qInfo(...) { if (qDebugFlag & DEBUG_INFO) { taosPrintLog("QRY INFO ",
255
, __VA_ARGS__); }}
#define qDebug(...) { if (qDebugFlag & DEBUG_DEBUG) { taosPrintLog("QRY DEBUG ", qDebugFlag, __VA_ARGS__); }}
#define qTrace(...) { if (qDebugFlag & DEBUG_TRACE) { taosPrintLog("QRY TRACE ", qDebugFlag, __VA_ARGS__); }}
...
...
src/tsdb/inc/tsdbMain.h
浏览文件 @
6b1f57a1
...
...
@@ -33,10 +33,12 @@ extern "C" {
extern
int
tsdbDebugFlag
;
#define tsdbError(...) { if (tsdbDebugFlag & DEBUG_ERROR) { taosPrintLog("ERROR TDB ", tsdbDebugFlag, __VA_ARGS__); }}
#define tsdbWarn(...) { if (tsdbDebugFlag & DEBUG_WARN) { taosPrintLog("WARN TDB ", tsdbDebugFlag, __VA_ARGS__); }}
#define tsdbTrace(...) { if (tsdbDebugFlag & DEBUG_TRACE) { taosPrintLog("TDB ", tsdbDebugFlag, __VA_ARGS__); }}
#define tsdbPrint(...) { taosPrintLog("TDB ", 255, __VA_ARGS__); }
#define tsdbFatal(...) { if (tsdbDebugFlag & DEBUG_FATAL) { taosPrintLog("TDB FATAL ", 255, __VA_ARGS__); }}
#define tsdbError(...) { if (tsdbDebugFlag & DEBUG_ERROR) { taosPrintLog("TDB ERROR ", 255, __VA_ARGS__); }}
#define tsdbWarn(...) { if (tsdbDebugFlag & DEBUG_WARN) { taosPrintLog("TDB WARN ", 255, __VA_ARGS__); }}
#define tsdbInfo(...) { if (tsdbDebugFlag & DEBUG_INFO) { taosPrintLog("TDB INFO ", 255, __VA_ARGS__); }}
#define tsdbDebug(...) { if (tsdbDebugFlag & DEBUG_DEBUG) { taosPrintLog("TDB DEBUG ", tsdbDebugFlag, __VA_ARGS__); }}
#define tsdbTrace(...) { if (tsdbDebugFlag & DEBUG_TRACE) { taosPrintLog("TDB TRACE ", tsdbDebugFlag, __VA_ARGS__); }}
#define TSDB_MAX_TABLE_SCHEMAS 16
#define TSDB_FILE_HEAD_SIZE 512
...
...
src/tsdb/src/tsdbBuffer.c
浏览文件 @
6b1f57a1
...
...
@@ -85,7 +85,7 @@ int tsdbOpenBufPool(STsdbRepo *pRepo) {
pPool
->
nBufBlocks
++
;
}
tsdb
Trace
(
"vgId:%d buffer pool is opened! bufBlockSize:%d tBufBlocks:%d nBufBlocks:%d"
,
REPO_ID
(
pRepo
),
tsdb
Debug
(
"vgId:%d buffer pool is opened! bufBlockSize:%d tBufBlocks:%d nBufBlocks:%d"
,
REPO_ID
(
pRepo
),
pPool
->
bufBlockSize
,
pPool
->
tBufBlocks
,
pPool
->
nBufBlocks
);
return
0
;
...
...
@@ -110,7 +110,7 @@ void tsdbCloseBufPool(STsdbRepo *pRepo) {
}
}
tsdb
Trace
(
"vgId:%d buffer pool is closed"
,
REPO_ID
(
pRepo
));
tsdb
Debug
(
"vgId:%d buffer pool is closed"
,
REPO_ID
(
pRepo
));
}
SListNode
*
tsdbAllocBufBlockFromPool
(
STsdbRepo
*
pRepo
)
{
...
...
@@ -134,7 +134,7 @@ SListNode *tsdbAllocBufBlockFromPool(STsdbRepo *pRepo) {
pBufBlock
->
offset
=
0
;
pBufBlock
->
remain
=
pBufPool
->
bufBlockSize
;
tsdb
Trace
(
"vgId:%d buffer block is allocated, blockId:%"
PRId64
,
REPO_ID
(
pRepo
),
pBufBlock
->
blockId
);
tsdb
Debug
(
"vgId:%d buffer block is allocated, blockId:%"
PRId64
,
REPO_ID
(
pRepo
),
pBufBlock
->
blockId
);
return
pNode
;
}
...
...
src/tsdb/src/tsdbFile.c
浏览文件 @
6b1f57a1
...
...
@@ -114,7 +114,7 @@ int tsdbOpenFileH(STsdbRepo *pRepo) {
}
}
tsdb
Trace
(
"vgId:%d file group %d init"
,
REPO_ID
(
pRepo
),
fid
);
tsdb
Debug
(
"vgId:%d file group %d init"
,
REPO_ID
(
pRepo
),
fid
);
pFileH
->
pFGroup
[
pFileH
->
nFGroups
++
]
=
fileGroup
;
qsort
((
void
*
)(
pFileH
->
pFGroup
),
pFileH
->
nFGroups
,
sizeof
(
SFileGroup
),
compFGroup
);
...
...
src/tsdb/src/tsdbMain.c
浏览文件 @
6b1f57a1
...
...
@@ -81,7 +81,7 @@ int32_t tsdbCreateRepo(char *rootDir, STsdbCfg *pCfg) {
if
(
tsdbSetRepoEnv
(
rootDir
,
pCfg
)
<
0
)
return
-
1
;
tsdb
Trace
(
tsdb
Debug
(
"vgId:%d tsdb env create succeed! cacheBlockSize %d totalBlocks %d maxTables %d daysPerFile %d keep "
"%d minRowsPerFileBlock %d maxRowsPerFileBlock %d precision %d compression %d"
,
pCfg
->
tsdbId
,
pCfg
->
cacheBlockSize
,
pCfg
->
totalBlocks
,
pCfg
->
maxTables
,
pCfg
->
daysPerFile
,
pCfg
->
keep
,
...
...
@@ -128,7 +128,7 @@ TSDB_REPO_T *tsdbOpenRepo(char *rootDir, STsdbAppH *pAppH) {
// pRepo->state = TSDB_REPO_STATE_ACTIVE;
tsdb
Trace
(
"vgId:%d open tsdb repository succeed!"
,
REPO_ID
(
pRepo
));
tsdb
Debug
(
"vgId:%d open tsdb repository succeed!"
,
REPO_ID
(
pRepo
));
return
(
TSDB_REPO_T
*
)
pRepo
;
...
...
@@ -157,7 +157,7 @@ void tsdbCloseRepo(TSDB_REPO_T *repo, int toCommit) {
tsdbCloseBufPool
(
pRepo
);
tsdbCloseMeta
(
pRepo
);
tsdbFreeRepo
(
pRepo
);
tsdb
Trace
(
"vgId:%d repository is closed"
,
vgId
);
tsdb
Debug
(
"vgId:%d repository is closed"
,
vgId
);
}
int32_t
tsdbInsertData
(
TSDB_REPO_T
*
repo
,
SSubmitMsg
*
pMsg
,
SShellSubmitRspMsg
*
pRsp
)
{
...
...
@@ -192,7 +192,7 @@ uint32_t tsdbGetFileInfo(TSDB_REPO_T *repo, char *name, uint32_t *index, uint32_
struct
stat
fState
;
tsdb
Trace
(
"vgId:%d name:%s index:%d eindex:%d"
,
pRepo
->
config
.
tsdbId
,
name
,
*
index
,
eindex
);
tsdb
Debug
(
"vgId:%d name:%s index:%d eindex:%d"
,
pRepo
->
config
.
tsdbId
,
name
,
*
index
,
eindex
);
ASSERT
(
*
index
<=
eindex
);
char
*
sdup
=
strdup
(
pRepo
->
rootDir
);
...
...
@@ -520,7 +520,7 @@ static int32_t tsdbSetRepoEnv(char *rootDir, STsdbCfg *pCfg) {
static
int32_t
tsdbUnsetRepoEnv
(
char
*
rootDir
)
{
taosRemoveDir
(
rootDir
);
tsdb
Trace
(
"repository %s is removed"
,
rootDir
);
tsdb
Debug
(
"repository %s is removed"
,
rootDir
);
return
0
;
}
...
...
@@ -842,7 +842,7 @@ static int tsdbInitSubmitBlkIter(SSubmitBlk *pBlock, SSubmitBlkIter *pIter) {
static
void
tsdbAlterCompression
(
STsdbRepo
*
pRepo
,
int8_t
compression
)
{
int8_t
ocompression
=
pRepo
->
config
.
compression
;
pRepo
->
config
.
compression
=
compression
;
tsdb
Trace
(
"vgId:%d tsdb compression is changed from %d to %d"
,
REPO_ID
(
pRepo
),
ocompression
,
compression
);
tsdb
Debug
(
"vgId:%d tsdb compression is changed from %d to %d"
,
REPO_ID
(
pRepo
),
ocompression
,
compression
);
}
static
int
tsdbAlterKeep
(
STsdbRepo
*
pRepo
,
int32_t
keep
)
{
...
...
@@ -884,7 +884,7 @@ static int tsdbAlterKeep(STsdbRepo *pRepo, int32_t keep) {
pthread_rwlock_unlock
(
&
(
pFileH
->
fhlock
));
}
tsdb
Trace
(
"vgId:%d keep is changed from %d to %d"
,
REPO_ID
(
pRepo
),
okeep
,
keep
);
tsdb
Debug
(
"vgId:%d keep is changed from %d to %d"
,
REPO_ID
(
pRepo
),
okeep
,
keep
);
return
0
;
}
...
...
@@ -915,7 +915,7 @@ static int tsdbAlterMaxTables(STsdbRepo *pRepo, int32_t maxTables) {
sizeof
(
STableData
*
)
*
(
maxTables
-
oldMaxTables
));
}
tsdb
Trace
(
"vgId:%d, tsdb maxTables is changed from %d to %d!"
,
pRepo
->
config
.
tsdbId
,
oldMaxTables
,
maxTables
);
tsdb
Debug
(
"vgId:%d, tsdb maxTables is changed from %d to %d!"
,
pRepo
->
config
.
tsdbId
,
oldMaxTables
,
maxTables
);
return
0
;
}
...
...
@@ -973,7 +973,7 @@ static int tsdbCheckTableSchema(STsdbRepo *pRepo, SSubmitBlk *pBlock, STable *pT
if
(
pBlock
->
sversion
==
sversion
)
return
0
;
if
(
pBlock
->
sversion
>
sversion
)
{
// need to config
tsdb
Trace
(
"vgId:%d table %s tid %d has version %d smaller than client version %d, try to config"
,
REPO_ID
(
pRepo
),
tsdb
Debug
(
"vgId:%d table %s tid %d has version %d smaller than client version %d, try to config"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TID
(
pTable
),
sversion
,
pBlock
->
sversion
);
if
(
pRepo
->
appH
.
configFunc
)
{
void
*
msg
=
(
*
pRepo
->
appH
.
configFunc
)(
REPO_ID
(
pRepo
),
TABLE_TID
(
pTable
));
...
...
@@ -1041,7 +1041,7 @@ static int tsdbAlterCacheTotalBlocks(STsdbRepo *pRepo, int totalBlocks) {
// pRepo->config.totalBlocks = totalBlocks;
// tsdbUnLockRepo((TsdbRepoT *)pRepo);
// tsdb
Trace
("vgId:%d, tsdb total cache blocks changed from %d to %d", pRepo->config.tsdbId, oldNumOfBlocks,
// tsdb
Debug
("vgId:%d, tsdb total cache blocks changed from %d to %d", pRepo->config.tsdbId, oldNumOfBlocks,
// totalBlocks);
return
0
;
}
...
...
src/tsdb/src/tsdbMemTable.c
浏览文件 @
6b1f57a1
...
...
@@ -111,7 +111,7 @@ int tsdbInsertRowToMem(STsdbRepo *pRepo, SDataRow row, STable *pTable) {
ASSERT
(
pTableData
->
numOfRows
==
tSkipListGetSize
(
pTableData
->
pData
));
}
tsdb
Trace
(
"vgId:%d a row is inserted to table %s tid %d uid %"
PRIu64
" key %"
PRIu64
,
REPO_ID
(
pRepo
),
tsdb
Debug
(
"vgId:%d a row is inserted to table %s tid %d uid %"
PRIu64
" key %"
PRIu64
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TID
(
pTable
),
TABLE_UID
(
pTable
),
key
);
return
0
;
...
...
@@ -369,7 +369,7 @@ static void *tsdbCommitData(void *arg) {
ASSERT
(
pRepo
->
commit
==
1
);
ASSERT
(
pMem
!=
NULL
);
tsdb
Print
(
"vgId:%d start to commit! keyFirst %"
PRId64
" keyLast %"
PRId64
" numOfRows %"
PRId64
,
REPO_ID
(
pRepo
),
tsdb
Info
(
"vgId:%d start to commit! keyFirst %"
PRId64
" keyLast %"
PRId64
" numOfRows %"
PRId64
,
REPO_ID
(
pRepo
),
pMem
->
keyFirst
,
pMem
->
keyLast
,
pMem
->
numOfRows
);
// Create the iterator to read from cache
...
...
@@ -417,7 +417,7 @@ _exit:
tsdbDestroyTableIters
(
iters
,
pCfg
->
maxTables
);
tsdbDestroyHelper
(
&
whelper
);
tsdbEndCommit
(
pRepo
);
tsdb
Print
(
"vgId:%d commit over"
,
pRepo
->
config
.
tsdbId
);
tsdb
Info
(
"vgId:%d commit over"
,
pRepo
->
config
.
tsdbId
);
return
NULL
;
}
...
...
@@ -509,7 +509,7 @@ static int tsdbCommitToFile(STsdbRepo *pRepo, int fid, SCommitIter *iters, SRWHe
// Check if there are data to commit to this file
int
hasDataToCommit
=
tsdbHasDataToCommit
(
iters
,
pCfg
->
maxTables
,
minKey
,
maxKey
);
if
(
!
hasDataToCommit
)
{
tsdb
Trace
(
"vgId:%d no data to commit to file %d"
,
REPO_ID
(
pRepo
),
fid
);
tsdb
Debug
(
"vgId:%d no data to commit to file %d"
,
REPO_ID
(
pRepo
),
fid
);
return
0
;
}
...
...
src/tsdb/src/tsdbMeta.c
浏览文件 @
6b1f57a1
...
...
@@ -125,7 +125,7 @@ int tsdbDropTable(TSDB_REPO_T *repo, STableId tableId) {
return
-
1
;
}
tsdb
Trace
(
"vgId:%d try to drop table %s type %d"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TYPE
(
pTable
));
tsdb
Debug
(
"vgId:%d try to drop table %s type %d"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TYPE
(
pTable
));
tid
=
TABLE_TID
(
pTable
);
tbname
=
strdup
(
TABLE_CHAR_NAME
(
pTable
));
...
...
@@ -146,7 +146,7 @@ int tsdbDropTable(TSDB_REPO_T *repo, STableId tableId) {
goto
_err
;
}
tsdb
Trace
(
"vgId:%d, table %s is dropped! tid:%d, uid:%"
PRId64
,
pRepo
->
config
.
tsdbId
,
tbname
,
tid
,
uid
);
tsdb
Debug
(
"vgId:%d, table %s is dropped! tid:%d, uid:%"
PRId64
,
pRepo
->
config
.
tsdbId
,
tbname
,
tid
,
uid
);
free
(
tbname
);
return
0
;
...
...
@@ -294,7 +294,7 @@ int tsdbUpdateTagValue(TSDB_REPO_T *repo, SUpdateTableTagValMsg *pMsg) {
}
if
(
schemaVersion
(
tsdbGetTableTagSchema
(
pTable
))
<
tversion
)
{
tsdb
Trace
(
"vgId:%d server tag version %d is older than client tag version %d, try to config"
,
REPO_ID
(
pRepo
),
tsdb
Debug
(
"vgId:%d server tag version %d is older than client tag version %d, try to config"
,
REPO_ID
(
pRepo
),
schemaVersion
(
tsdbGetTableTagSchema
(
pTable
)),
tversion
);
void
*
msg
=
(
*
pRepo
->
appH
.
configFunc
)(
pRepo
->
config
.
tsdbId
,
htonl
(
pMsg
->
tid
));
if
(
msg
==
NULL
)
return
-
1
;
...
...
@@ -400,7 +400,7 @@ int tsdbOpenMeta(STsdbRepo *pRepo) {
goto
_err
;
}
tsdb
Trace
(
"vgId:%d open TSDB meta succeed"
,
REPO_ID
(
pRepo
));
tsdb
Debug
(
"vgId:%d open TSDB meta succeed"
,
REPO_ID
(
pRepo
));
tfree
(
fname
);
return
0
;
...
...
@@ -427,7 +427,7 @@ int tsdbCloseMeta(STsdbRepo *pRepo) {
listNodeFree
(
pNode
);
}
tsdb
Trace
(
"vgId:%d TSDB meta is closed"
,
REPO_ID
(
pRepo
));
tsdb
Debug
(
"vgId:%d TSDB meta is closed"
,
REPO_ID
(
pRepo
));
return
0
;
}
...
...
@@ -554,15 +554,15 @@ int tsdbUnlockRepoMeta(STsdbRepo *pRepo) {
void
tsdbRefTable
(
STable
*
pTable
)
{
int16_t
ref
=
T_REF_INC
(
pTable
);
UNUSED
(
ref
);
// tsdb
Trace
("ref table %"PRIu64", tid:%d, refCount:%d", TABLE_UID(pTable), TABLE_TID(pTable), ref);
// tsdb
Debug
("ref table %"PRIu64", tid:%d, refCount:%d", TABLE_UID(pTable), TABLE_TID(pTable), ref);
}
void
tsdbUnRefTable
(
STable
*
pTable
)
{
int16_t
ref
=
T_REF_DEC
(
pTable
);
tsdb
Trace
(
"unref table uid:%"
PRIu64
", tid:%d, refCount:%d"
,
TABLE_UID
(
pTable
),
TABLE_TID
(
pTable
),
ref
);
tsdb
Debug
(
"unref table uid:%"
PRIu64
", tid:%d, refCount:%d"
,
TABLE_UID
(
pTable
),
TABLE_TID
(
pTable
),
ref
);
if
(
ref
==
0
)
{
// tsdb
Trace
("destory table name:%s uid:%"PRIu64", tid:%d", TABLE_CHAR_NAME(pTable), TABLE_UID(pTable), TABLE_TID(pTable));
// tsdb
Debug
("destory table name:%s uid:%"PRIu64", tid:%d", TABLE_CHAR_NAME(pTable), TABLE_UID(pTable), TABLE_TID(pTable));
if
(
TABLE_TYPE
(
pTable
)
==
TSDB_CHILD_TABLE
)
{
tsdbUnRefTable
(
pTable
->
pSuper
);
...
...
@@ -598,7 +598,7 @@ static int tsdbRestoreTable(void *pHandle, void *cont, int contLen) {
return
-
1
;
}
tsdb
Trace
(
"vgId:%d table %s tid %d uid %"
PRIu64
" is restored from file"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
tsdb
Debug
(
"vgId:%d table %s tid %d uid %"
PRIu64
" is restored from file"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TID
(
pTable
),
TABLE_UID
(
pTable
));
return
0
;
}
...
...
@@ -717,7 +717,7 @@ _err:
static
void
tsdbFreeTable
(
STable
*
pTable
)
{
if
(
pTable
)
{
tsdb
Trace
(
"table %s is destroyed"
,
TABLE_CHAR_NAME
(
pTable
));
tsdb
Debug
(
"table %s is destroyed"
,
TABLE_CHAR_NAME
(
pTable
));
tfree
(
TABLE_NAME
(
pTable
));
if
(
TABLE_TYPE
(
pTable
)
!=
TSDB_CHILD_TABLE
)
{
for
(
int
i
=
0
;
i
<
TSDB_MAX_TABLE_SCHEMAS
;
i
++
)
{
...
...
@@ -771,7 +771,7 @@ static int tsdbAddTableToMeta(STsdbRepo *pRepo, STable *pTable, bool addIdx) {
}
else
{
if
(
TABLE_TYPE
(
pTable
)
==
TSDB_CHILD_TABLE
&&
addIdx
)
{
// add STABLE to the index
if
(
tsdbAddTableIntoIndex
(
pMeta
,
pTable
)
<
0
)
{
tsdb
Trace
(
"vgId:%d failed to add table %s to meta while add table to index since %s"
,
REPO_ID
(
pRepo
),
tsdb
Debug
(
"vgId:%d failed to add table %s to meta while add table to index since %s"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
tstrerror
(
terrno
));
goto
_err
;
}
...
...
@@ -799,7 +799,7 @@ static int tsdbAddTableToMeta(STsdbRepo *pRepo, STable *pTable, bool addIdx) {
pTable
->
cqhandle
=
(
*
pRepo
->
appH
.
cqCreateFunc
)(
pRepo
->
appH
.
cqH
,
TABLE_UID
(
pTable
),
TABLE_TID
(
pTable
),
pTable
->
sql
,
tsdbGetTableSchema
(
pTable
));
}
tsdb
Trace
(
"vgId:%d table %s tid %d uid %"
PRIu64
" is added to meta"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
tsdb
Debug
(
"vgId:%d table %s tid %d uid %"
PRIu64
" is added to meta"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
),
TABLE_TID
(
pTable
),
TABLE_UID
(
pTable
));
return
0
;
...
...
@@ -858,7 +858,7 @@ static void tsdbRemoveTableFromMeta(STsdbRepo *pRepo, STable *pTable, bool rmFro
}
if
(
lock
)
tsdbUnlockRepoMeta
(
pRepo
);
tsdb
Trace
(
"vgId:%d table %s is removed from meta"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
));
tsdb
Debug
(
"vgId:%d table %s is removed from meta"
,
REPO_ID
(
pRepo
),
TABLE_CHAR_NAME
(
pTable
));
tsdbUnRefTable
(
pTable
);
}
...
...
src/tsdb/src/tsdbRWHelper.c
浏览文件 @
6b1f57a1
...
...
@@ -715,7 +715,7 @@ static int tsdbWriteBlockToFile(SRWHelper *pHelper, SFile *pFile, SDataCols *pDa
pCompBlock
->
keyFirst
=
dataColsKeyFirst
(
pDataCols
);
pCompBlock
->
keyLast
=
dataColsKeyAt
(
pDataCols
,
rowsToWrite
-
1
);
tsdb
Trace
(
"vgId:%d tid:%d a block of data is written to file %s, offset %"
PRId64
tsdb
Debug
(
"vgId:%d tid:%d a block of data is written to file %s, offset %"
PRId64
" numOfRows %d len %d numOfCols %"
PRId16
" keyFirst %"
PRId64
" keyLast %"
PRId64
,
REPO_ID
(
helperRepo
(
pHelper
)),
pHelper
->
tableInfo
.
tid
,
pFile
->
fname
,
(
int64_t
)(
pCompBlock
->
offset
),
(
int
)(
pCompBlock
->
numOfRows
),
pCompBlock
->
len
,
pCompBlock
->
numOfCols
,
pCompBlock
->
keyFirst
,
...
...
@@ -916,7 +916,7 @@ static int tsdbInsertSuperBlock(SRWHelper *pHelper, SCompBlock *pCompBlock, int
ASSERT
(
pHelper
->
pCompInfo
->
blocks
[
0
].
keyLast
<
pHelper
->
pCompInfo
->
blocks
[
1
].
keyFirst
);
}
tsdb
Trace
(
"vgId:%d tid:%d a super block is inserted at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
tsdb
Debug
(
"vgId:%d tid:%d a super block is inserted at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
blkIdx
);
return
0
;
...
...
@@ -1001,7 +1001,7 @@ static int tsdbAddSubBlock(SRWHelper *pHelper, SCompBlock *pCompBlock, int blkId
pIdx
->
maxKey
=
pHelper
->
pCompInfo
->
blocks
[
pIdx
->
numOfBlocks
-
1
].
keyLast
;
pIdx
->
hasLast
=
pHelper
->
pCompInfo
->
blocks
[
pIdx
->
numOfBlocks
-
1
].
last
;
tsdb
Trace
(
"vgId:%d tid:%d a subblock is added at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
blkIdx
);
tsdb
Debug
(
"vgId:%d tid:%d a subblock is added at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
blkIdx
);
return
0
;
...
...
@@ -1041,7 +1041,7 @@ static int tsdbUpdateSuperBlock(SRWHelper *pHelper, SCompBlock *pCompBlock, int
pIdx
->
maxKey
=
pHelper
->
pCompInfo
->
blocks
[
pIdx
->
numOfBlocks
-
1
].
keyLast
;
pIdx
->
hasLast
=
pHelper
->
pCompInfo
->
blocks
[
pIdx
->
numOfBlocks
-
1
].
last
;
tsdb
Trace
(
"vgId:%d tid:%d a super block is updated at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
tsdb
Debug
(
"vgId:%d tid:%d a super block is updated at index %d"
,
REPO_ID
(
pHelper
->
pRepo
),
pHelper
->
tableInfo
.
tid
,
blkIdx
);
return
0
;
...
...
src/tsdb/src/tsdbRead.c
浏览文件 @
6b1f57a1
...
...
@@ -199,7 +199,7 @@ TsdbQueryHandleT* tsdbQueryTables(TSDB_REPO_T* tsdb, STsdbQueryCond* pCond, STab
}
}
tsdb
Trace
(
"%p total numOfTable:%zu in query"
,
pQueryHandle
,
taosArrayGetSize
(
pQueryHandle
->
pTableCheckInfo
));
tsdb
Debug
(
"%p total numOfTable:%zu in query"
,
pQueryHandle
,
taosArrayGetSize
(
pQueryHandle
->
pTableCheckInfo
));
tsdbInitDataBlockLoadInfo
(
&
pQueryHandle
->
dataBlockLoadInfo
);
tsdbInitCompBlockLoadInfo
(
&
pQueryHandle
->
compBlockLoadInfo
);
...
...
@@ -288,10 +288,10 @@ static bool initTableMemIterator(STsdbQueryHandle* pHandle, STableCheckInfo* pCh
SDataRow
row
=
SL_GET_NODE_DATA
(
node
);
TSKEY
key
=
dataRowKey
(
row
);
// first timestamp in buffer
tsdb
Trace
(
"%p uid:%"
PRId64
", tid:%d check data in mem from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
tsdb
Debug
(
"%p uid:%"
PRId64
", tid:%d check data in mem from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
,
key
,
order
,
pHandle
->
qinfo
);
}
else
{
tsdb
Trace
(
"%p uid:%"
PRId64
", tid:%d no data in mem"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
);
tsdb
Debug
(
"%p uid:%"
PRId64
", tid:%d no data in mem"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
);
}
if
(
!
imemEmpty
)
{
...
...
@@ -300,10 +300,10 @@ static bool initTableMemIterator(STsdbQueryHandle* pHandle, STableCheckInfo* pCh
SDataRow
row
=
SL_GET_NODE_DATA
(
node
);
TSKEY
key
=
dataRowKey
(
row
);
// first timestamp in buffer
tsdb
Trace
(
"%p uid:%"
PRId64
", tid:%d check data in imem from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
tsdb
Debug
(
"%p uid:%"
PRId64
", tid:%d check data in imem from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
,
key
,
order
,
pHandle
->
qinfo
);
}
else
{
tsdb
Trace
(
"%p uid:%"
PRId64
", tid:%d no data in imem"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
);
tsdb
Debug
(
"%p uid:%"
PRId64
", tid:%d no data in imem"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
);
}
return
true
;
...
...
@@ -403,7 +403,7 @@ static bool hasMoreDataInCache(STsdbQueryHandle* pHandle) {
}
pCheckInfo
->
lastKey
=
dataRowKey
(
row
);
// first timestamp in buffer
tsdb
Trace
(
"%p uid:%"
PRId64
", tid:%d check data in buffer from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
tsdb
Debug
(
"%p uid:%"
PRId64
", tid:%d check data in buffer from skey:%"
PRId64
", order:%d, %p"
,
pHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
,
pCheckInfo
->
lastKey
,
pHandle
->
order
,
pHandle
->
qinfo
);
// all data in mem are checked already.
...
...
@@ -616,7 +616,7 @@ static bool doLoadFileDataBlock(STsdbQueryHandle* pQueryHandle, SCompBlock* pBlo
tfree
(
data
);
int64_t
et
=
taosGetTimestampUs
()
-
st
;
tsdb
Trace
(
"%p load file block into buffer, elapsed time:%"
PRId64
" us"
,
pQueryHandle
,
et
);
tsdb
Debug
(
"%p load file block into buffer, elapsed time:%"
PRId64
" us"
,
pQueryHandle
,
et
);
return
blockLoaded
;
}
...
...
@@ -1142,7 +1142,7 @@ static void doMergeTwoLevelData(STsdbQueryHandle* pQueryHandle, STableCheckInfo*
cur
->
rows
=
numOfRows
;
cur
->
pos
=
pos
;
tsdb
Trace
(
"%p uid:%"
PRIu64
",tid:%d data block created, brange:%"
PRIu64
"-%"
PRIu64
" rows:%d, %p"
,
pQueryHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
,
cur
->
win
.
skey
,
tsdb
Debug
(
"%p uid:%"
PRIu64
",tid:%d data block created, brange:%"
PRIu64
"-%"
PRIu64
" rows:%d, %p"
,
pQueryHandle
,
pCheckInfo
->
tableId
.
uid
,
pCheckInfo
->
tableId
.
tid
,
cur
->
win
.
skey
,
cur
->
win
.
ekey
,
cur
->
rows
,
pQueryHandle
->
qinfo
);
}
...
...
@@ -1309,12 +1309,12 @@ static int32_t createDataBlocksInfo(STsdbQueryHandle* pQueryHandle, int32_t numO
memcpy
(
pQueryHandle
->
pDataBlockInfo
,
sup
.
pDataBlockInfo
[
0
],
sizeof
(
STableBlockInfo
)
*
numOfBlocks
);
cleanBlockOrderSupporter
(
&
sup
,
numOfQualTables
);
tsdb
Trace
(
"%p create data blocks info struct completed for 1 table, %d blocks not sorted %p "
,
pQueryHandle
,
cnt
,
tsdb
Debug
(
"%p create data blocks info struct completed for 1 table, %d blocks not sorted %p "
,
pQueryHandle
,
cnt
,
pQueryHandle
->
qinfo
);
return
TSDB_CODE_SUCCESS
;
}
tsdb
Trace
(
"%p create data blocks info struct completed, %d blocks in %d tables %p"
,
pQueryHandle
,
cnt
,
tsdb
Debug
(
"%p create data blocks info struct completed, %d blocks in %d tables %p"
,
pQueryHandle
,
cnt
,
numOfQualTables
,
pQueryHandle
->
qinfo
);
assert
(
cnt
<=
numOfBlocks
&&
numOfQualTables
<=
numOfTables
);
// the pTableQueryInfo[j]->numOfBlocks may be 0
...
...
@@ -1351,7 +1351,7 @@ static int32_t createDataBlocksInfo(STsdbQueryHandle* pQueryHandle, int32_t numO
* }
*/
tsdb
Trace
(
"%p %d data blocks sort completed"
,
pQueryHandle
,
cnt
);
tsdb
Debug
(
"%p %d data blocks sort completed"
,
pQueryHandle
,
cnt
);
cleanBlockOrderSupporter
(
&
sup
,
numOfTables
);
free
(
pTree
);
...
...
@@ -1372,7 +1372,7 @@ static bool getDataBlocksInFilesImpl(STsdbQueryHandle* pQueryHandle) {
break
;
}
tsdb
Trace
(
"%p %d blocks found in file for %d table(s), fid:%d, %p"
,
pQueryHandle
,
numOfBlocks
,
tsdb
Debug
(
"%p %d blocks found in file for %d table(s), fid:%d, %p"
,
pQueryHandle
,
numOfBlocks
,
numOfTables
,
pQueryHandle
->
pFileGroup
->
fileId
,
pQueryHandle
->
qinfo
);
assert
(
numOfBlocks
>=
0
);
...
...
@@ -1696,7 +1696,7 @@ static int tsdbReadRowsFromCache(STableCheckInfo* pCheckInfo, TSKEY maxKey, int
TSKEY
key
=
dataRowKey
(
row
);
if
((
key
>
maxKey
&&
ASCENDING_TRAVERSE
(
pQueryHandle
->
order
))
||
(
key
<
maxKey
&&
!
ASCENDING_TRAVERSE
(
pQueryHandle
->
order
)))
{
tsdb
Trace
(
"%p key:%"
PRIu64
" beyond qrange:%"
PRId64
" - %"
PRId64
", no more data in buffer"
,
pQueryHandle
,
key
,
pQueryHandle
->
window
.
skey
,
tsdb
Debug
(
"%p key:%"
PRIu64
" beyond qrange:%"
PRId64
" - %"
PRId64
", no more data in buffer"
,
pQueryHandle
,
key
,
pQueryHandle
->
window
.
skey
,
pQueryHandle
->
window
.
ekey
);
break
;
...
...
@@ -1729,7 +1729,7 @@ static int tsdbReadRowsFromCache(STableCheckInfo* pCheckInfo, TSKEY maxKey, int
}
int64_t
elapsedTime
=
taosGetTimestampUs
()
-
st
;
tsdb
Trace
(
"%p build data block from cache completed, elapsed time:%"
PRId64
" us, numOfRows:%d, numOfCols:%d"
,
pQueryHandle
,
tsdb
Debug
(
"%p build data block from cache completed, elapsed time:%"
PRId64
" us, numOfRows:%d, numOfCols:%d"
,
pQueryHandle
,
elapsedTime
,
numOfRows
,
numOfCols
);
return
numOfRows
;
...
...
@@ -2032,7 +2032,7 @@ SArray* createTableGroup(SArray* pTableList, STSchema* pTagSchema, SColIndex* pC
size_t
size
=
taosArrayGetSize
(
pTableList
);
if
(
size
==
0
)
{
tsdb
Trace
(
"no qualified tables"
);
tsdb
Debug
(
"no qualified tables"
);
return
pTableGroup
;
}
...
...
@@ -2047,7 +2047,7 @@ SArray* createTableGroup(SArray* pTableList, STSchema* pTagSchema, SColIndex* pC
}
taosArrayPush
(
pTableGroup
,
&
sa
);
tsdb
Trace
(
"all %zu tables belong to one group"
,
size
);
tsdb
Debug
(
"all %zu tables belong to one group"
,
size
);
}
else
{
STableGroupSupporter
*
pSupp
=
(
STableGroupSupporter
*
)
calloc
(
1
,
sizeof
(
STableGroupSupporter
));
pSupp
->
numOfCols
=
numOfOrderCols
;
...
...
@@ -2173,7 +2173,7 @@ int32_t tsdbQuerySTableByTagCond(TSDB_REPO_T* tsdb, uint64_t uid, const char* pT
pGroupInfo
->
numOfTables
=
taosArrayGetSize
(
res
);
pGroupInfo
->
pGroupList
=
createTableGroup
(
res
,
pTagSchema
,
pColIndex
,
numOfCols
);
tsdb
Trace
(
"%p no table name/tag condition, all tables belong to one group, numOfTables:%zu"
,
tsdb
,
pGroupInfo
->
numOfTables
);
tsdb
Debug
(
"%p no table name/tag condition, all tables belong to one group, numOfTables:%zu"
,
tsdb
,
pGroupInfo
->
numOfTables
);
taosArrayDestroy
(
res
);
if
(
tsdbUnlockRepoMeta
(
tsdb
)
<
0
)
goto
_error
;
...
...
@@ -2215,7 +2215,7 @@ int32_t tsdbQuerySTableByTagCond(TSDB_REPO_T* tsdb, uint64_t uid, const char* pT
pGroupInfo
->
numOfTables
=
taosArrayGetSize
(
res
);
pGroupInfo
->
pGroupList
=
createTableGroup
(
res
,
pTagSchema
,
pColIndex
,
numOfCols
);
tsdb
Trace
(
"%p stable tid:%d, uid:%"
PRIu64
" query, numOfTables:%zu, belong to %zu groups"
,
tsdb
,
pTable
->
tableId
.
tid
,
tsdb
Debug
(
"%p stable tid:%d, uid:%"
PRIu64
" query, numOfTables:%zu, belong to %zu groups"
,
tsdb
,
pTable
->
tableId
.
tid
,
pTable
->
tableId
.
uid
,
pGroupInfo
->
numOfTables
,
taosArrayGetSize
(
pGroupInfo
->
pGroupList
));
taosArrayDestroy
(
res
);
...
...
src/vnode/inc/vnodeInt.h
浏览文件 @
6b1f57a1
...
...
@@ -27,10 +27,10 @@ extern "C" {
extern
int32_t
vDebugFlag
;
#define vFatal(...) { if (vDebugFlag & DEBUG_FATAL) { taosPrintLog("VND FATAL ",
vDebugFlag
, __VA_ARGS__); }}
#define vError(...) { if (vDebugFlag & DEBUG_ERROR) { taosPrintLog("VND ERROR ",
vDebugFlag
, __VA_ARGS__); }}
#define vWarn(...) { if (vDebugFlag & DEBUG_WARN) { taosPrintLog("VND WARN ",
vDebugFlag
, __VA_ARGS__); }}
#define vInfo(...) { if (vDebugFlag & DEBUG_INFO) { taosPrintLog("VND INFO ",
vDebugFlag
, __VA_ARGS__); }}
#define vFatal(...) { if (vDebugFlag & DEBUG_FATAL) { taosPrintLog("VND FATAL ",
255
, __VA_ARGS__); }}
#define vError(...) { if (vDebugFlag & DEBUG_ERROR) { taosPrintLog("VND ERROR ",
255
, __VA_ARGS__); }}
#define vWarn(...) { if (vDebugFlag & DEBUG_WARN) { taosPrintLog("VND WARN ",
255
, __VA_ARGS__); }}
#define vInfo(...) { if (vDebugFlag & DEBUG_INFO) { taosPrintLog("VND INFO ",
255
, __VA_ARGS__); }}
#define vDebug(...) { if (vDebugFlag & DEBUG_DEBUG) { taosPrintLog("VND DEBUG ", vDebugFlag, __VA_ARGS__); }}
#define vTrace(...) { if (vDebugFlag & DEBUG_TRACE) { taosPrintLog("VND TRACE ", vDebugFlag, __VA_ARGS__); }}
...
...
src/wal/src/walMain.c
浏览文件 @
6b1f57a1
...
...
@@ -31,10 +31,10 @@
#define walPrefix "wal"
#define wFatal(...) { if (wDebugFlag & DEBUG_FATAL) { taosPrintLog("WAL FATAL ",
wDebugFlag
, __VA_ARGS__); }}
#define wError(...) { if (wDebugFlag & DEBUG_ERROR) { taosPrintLog("WAL ERROR ",
wDebugFlag
, __VA_ARGS__); }}
#define wWarn(...) { if (wDebugFlag & DEBUG_WARN) { taosPrintLog("WAL WARN ",
wDebugFlag
, __VA_ARGS__); }}
#define wInfo(...) { if (wDebugFlag & DEBUG_INFO) { taosPrintLog("WAL INFO ",
wDebugFlag
, __VA_ARGS__); }}
#define wFatal(...) { if (wDebugFlag & DEBUG_FATAL) { taosPrintLog("WAL FATAL ",
255
, __VA_ARGS__); }}
#define wError(...) { if (wDebugFlag & DEBUG_ERROR) { taosPrintLog("WAL ERROR ",
255
, __VA_ARGS__); }}
#define wWarn(...) { if (wDebugFlag & DEBUG_WARN) { taosPrintLog("WAL WARN ",
255
, __VA_ARGS__); }}
#define wInfo(...) { if (wDebugFlag & DEBUG_INFO) { taosPrintLog("WAL INFO ",
255
, __VA_ARGS__); }}
#define wDebug(...) { if (wDebugFlag & DEBUG_DEBUG) { taosPrintLog("WAL DEBUG ", wDebugFlag, __VA_ARGS__); }}
#define wTrace(...) { if (wDebugFlag & DEBUG_TRACE) { taosPrintLog("WAL TRACE ", wDebugFlag, __VA_ARGS__); }}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录