Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
0cd2043c
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1187
Star
22018
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看板
提交
0cd2043c
编写于
3月 14, 2020
作者:
H
hjxilinx
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
refactor codes.
上级
b9888eaf
变更
24
展开全部
隐藏空白更改
内联
并排
Showing
24 changed file
with
1117 addition
and
1119 deletion
+1117
-1119
src/client/inc/tscCache.h
src/client/inc/tscCache.h
+0
-35
src/client/inc/tscJoinProcess.h
src/client/inc/tscJoinProcess.h
+0
-116
src/client/inc/tsclient.h
src/client/inc/tsclient.h
+1
-1
src/client/src/tscFunctionImpl.c
src/client/src/tscFunctionImpl.c
+2
-1
src/client/src/tscJoinProcess.c
src/client/src/tscJoinProcess.c
+2
-921
src/client/src/tscParseInsert.c
src/client/src/tscParseInsert.c
+1
-1
src/client/src/tscSQLParser.c
src/client/src/tscSQLParser.c
+1
-1
src/client/src/tscSql.c
src/client/src/tscSql.c
+1
-0
src/client/src/tscUtil.c
src/client/src/tscUtil.c
+1
-1
src/mnode/src/mgmtTable.c
src/mnode/src/mgmtTable.c
+1
-1
src/query/inc/qast.h
src/query/inc/qast.h
+0
-0
src/query/inc/qextbuffer.h
src/query/inc/qextbuffer.h
+0
-7
src/query/inc/qtsbuf.h
src/query/inc/qtsbuf.h
+142
-0
src/query/src/qast.c
src/query/src/qast.c
+3
-1
src/query/src/qextbuffer.c
src/query/src/qextbuffer.c
+0
-23
src/query/src/qtsbuf.c
src/query/src/qtsbuf.c
+923
-0
src/util/inc/tutil.h
src/util/inc/tutil.h
+7
-0
src/util/src/hash.c
src/util/src/hash.c
+2
-0
src/util/src/tutil.c
src/util/src/tutil.c
+23
-0
src/vnode/detail/inc/vnodeSupertableQuery.h
src/vnode/detail/inc/vnodeSupertableQuery.h
+2
-4
src/vnode/detail/src/vnodeRead.c
src/vnode/detail/src/vnodeRead.c
+1
-1
src/vnode/detail/src/vnodeSupertableQuery.c
src/vnode/detail/src/vnodeSupertableQuery.c
+1
-2
src/vnode/detail/src/vnodeTagMgmt.c
src/vnode/detail/src/vnodeTagMgmt.c
+1
-1
src/vnode/detail/src/vnodeUtil.c
src/vnode/detail/src/vnodeUtil.c
+2
-2
未找到文件。
src/client/inc/tscCache.h
已删除
100644 → 0
浏览文件 @
b9888eaf
/*
* Copyright (c) 2019 TAOS Data, Inc. <jhtao@taosdata.com>
*
* This program is free software: you can use, redistribute, and/or modify
* it under the terms of the GNU Affero General Public License, version 3
* or later ("AGPL"), as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef TDENGINE_TSCCACHE_H
#define TDENGINE_TSCCACHE_H
#ifdef __cplusplus
extern
"C"
{
#endif
void
*
taosOpenConnCache
(
int
maxSessions
,
void
(
*
cleanFp
)(
void
*
),
void
*
tmrCtrl
,
int64_t
keepTimer
);
void
taosCloseConnCache
(
void
*
handle
);
void
*
taosAddConnIntoCache
(
void
*
handle
,
void
*
data
,
uint32_t
ip
,
uint16_t
port
,
char
*
user
);
void
*
taosGetConnFromCache
(
void
*
handle
,
uint32_t
ip
,
uint16_t
port
,
char
*
user
);
#ifdef __cplusplus
}
#endif
#endif // TDENGINE_TSCACHE_H
src/client/inc/tscJoinProcess.h
浏览文件 @
0cd2043c
...
...
@@ -24,7 +24,6 @@ extern "C" {
#include "tsclient.h"
void
tscFetchDatablockFromSubquery
(
SSqlObj
*
pSql
);
void
tscGetQualifiedTSList
(
SSqlObj
*
pSql
,
SJoinSubquerySupporter
*
p1
,
SJoinSubquerySupporter
*
p2
,
int32_t
*
num
);
void
tscSetupOutputColumnIndex
(
SSqlObj
*
pSql
);
int32_t
tscLaunchSecondPhaseSubqueries
(
SSqlObj
*
pSql
);
...
...
@@ -33,121 +32,6 @@ void tscJoinQueryCallback(void* param, TAOS_RES* tres, int code);
SJoinSubquerySupporter
*
tscCreateJoinSupporter
(
SSqlObj
*
pSql
,
SSubqueryState
*
pState
,
int32_t
index
);
void
tscDestroyJoinSupporter
(
SJoinSubquerySupporter
*
pSupporter
);
#define MEM_BUF_SIZE (1<<20)
#define TS_COMP_BLOCK_PADDING 0xFFFFFFFF
#define TS_COMP_FILE_MAGIC 0x87F5EC4C
#define TS_COMP_FILE_VNODE_MAX 512
typedef
struct
STSList
{
char
*
rawBuf
;
int32_t
allocSize
;
int32_t
threshold
;
int32_t
len
;
}
STSList
;
typedef
struct
STSRawBlock
{
int32_t
vnode
;
int64_t
tag
;
TSKEY
*
ts
;
int32_t
len
;
}
STSRawBlock
;
typedef
struct
STSElem
{
TSKEY
ts
;
int64_t
tag
;
int32_t
vnode
;
}
STSElem
;
typedef
struct
STSCursor
{
int32_t
vnodeIndex
;
int32_t
blockIndex
;
int32_t
tsIndex
;
int32_t
order
;
}
STSCursor
;
typedef
struct
STSBlock
{
int64_t
tag
;
// tag value
int32_t
numOfElem
;
// number of elements
int32_t
compLen
;
// size after compressed
int32_t
padding
;
// 0xFFFFFFFF by default, after the payload
char
*
payload
;
// actual data that is compressed
}
STSBlock
;
typedef
struct
STSVnodeBlockInfo
{
int32_t
vnode
;
/*
* The size of buffer file is not expected to be greater than 2G,
* and the offset of int32_t type is enough
*/
int32_t
offset
;
int32_t
numOfBlocks
;
int32_t
compLen
;
}
STSVnodeBlockInfo
;
typedef
struct
STSVnodeBlockInfoEx
{
STSVnodeBlockInfo
info
;
int32_t
len
;
// length before compress
}
STSVnodeBlockInfoEx
;
typedef
struct
STSBuf
{
FILE
*
f
;
char
path
[
PATH_MAX
];
uint32_t
fileSize
;
STSVnodeBlockInfoEx
*
pData
;
int32_t
numOfAlloc
;
int32_t
numOfVnodes
;
char
*
assistBuf
;
int32_t
bufSize
;
STSBlock
block
;
STSList
tsData
;
// uncompressed raw ts data
uint64_t
numOfTotal
;
bool
autoDelete
;
int32_t
tsOrder
;
// order of timestamp in ts comp buffer
STSCursor
cur
;
}
STSBuf
;
typedef
struct
STSBufFileHeader
{
uint32_t
magic
;
// file magic number
uint32_t
numOfVnode
;
// number of vnode stored in current file
uint32_t
tsOrder
;
// timestamp order in current file
}
STSBufFileHeader
;
STSBuf
*
tsBufCreate
(
bool
autoDelete
);
STSBuf
*
tsBufCreateFromFile
(
const
char
*
path
,
bool
autoDelete
);
STSBuf
*
tsBufCreateFromCompBlocks
(
const
char
*
pData
,
int32_t
numOfBlocks
,
int32_t
len
,
int32_t
tsOrder
);
void
*
tsBufDestory
(
STSBuf
*
pTSBuf
);
void
tsBufAppend
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
,
int64_t
tag
,
const
char
*
pData
,
int32_t
len
);
int32_t
tsBufMerge
(
STSBuf
*
pDestBuf
,
const
STSBuf
*
pSrcBuf
,
int32_t
vnodeIdx
);
STSVnodeBlockInfo
*
tsBufGetVnodeBlockInfo
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
);
void
tsBufFlush
(
STSBuf
*
pTSBuf
);
void
tsBufResetPos
(
STSBuf
*
pTSBuf
);
STSElem
tsBufGetElem
(
STSBuf
*
pTSBuf
);
bool
tsBufNextPos
(
STSBuf
*
pTSBuf
);
STSElem
tsBufGetElemStartPos
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
,
int64_t
tag
);
STSCursor
tsBufGetCursor
(
STSBuf
*
pTSBuf
);
void
tsBufSetTraverseOrder
(
STSBuf
*
pTSBuf
,
int32_t
order
);
void
tsBufSetCursor
(
STSBuf
*
pTSBuf
,
STSCursor
*
pCur
);
STSBuf
*
tsBufClone
(
STSBuf
*
pTSBuf
);
/**
* display all data in comp block file, for debug purpose only
* @param pTSBuf
*/
void
tsBufDisplay
(
STSBuf
*
pTSBuf
);
#ifdef __cplusplus
}
#endif
...
...
src/client/inc/tsclient.h
浏览文件 @
0cd2043c
...
...
@@ -25,13 +25,13 @@ extern "C" {
#include "taosmsg.h"
#include "tglobalcfg.h"
#include "tlog.h"
#include "tscCache.h"
#include "taosdef.h"
#include "tsqlfunction.h"
#include "tutil.h"
#include "trpc.h"
#include "qsqltype.h"
#include "qsqlparser.h"
#include "qtsbuf.h"
#define TSC_GET_RESPTR_BASE(res, _queryinfo, col) (res->data + ((_queryinfo)->fieldsInfo.pSqlExpr[col]->offset) * res->numOfRows)
...
...
src/client/src/tscFunctionImpl.c
浏览文件 @
0cd2043c
...
...
@@ -14,14 +14,15 @@
*/
#include "os.h"
#include "qast.h"
#include "qextbuffer.h"
#include "qhistogram.h"
#include "qinterpolation.h"
#include "qpercentile.h"
#include "qsyntaxtreefunction.h"
#include "qtsbuf.h"
#include "taosdef.h"
#include "taosmsg.h"
#include "tast.h"
#include "tlog.h"
#include "tscJoinProcess.h"
#include "tscompression.h"
...
...
src/client/src/tscJoinProcess.c
浏览文件 @
0cd2043c
此差异已折叠。
点击以展开。
src/client/src/tscParseInsert.c
浏览文件 @
0cd2043c
...
...
@@ -1317,7 +1317,7 @@ int tsParseSql(SSqlObj *pSql, bool multiVnodeInsertion) {
pSql
->
fetchFp
=
pSql
->
fp
;
// replace user defined callback function with multi-insert proxy function
pSql
->
fp
=
launchMultivnodeInsert
;
pSql
->
fp
=
(
void
(
*
)())
launchMultivnodeInsert
;
}
ret
=
tsParseInsertSql
(
pSql
);
...
...
src/client/src/tscSQLParser.c
浏览文件 @
0cd2043c
...
...
@@ -17,12 +17,12 @@
#define _DEFAULT_SOURCE
#include "os.h"
#include "qast.h"
#include "taos.h"
#include "taosmsg.h"
#include "tstoken.h"
#include "tstrbuild.h"
#include "ttime.h"
#include "tast.h"
#include "tscUtil.h"
#include "tschemautil.h"
...
...
src/client/src/tscSql.c
浏览文件 @
0cd2043c
...
...
@@ -29,6 +29,7 @@
#include "ttimer.h"
#include "tutil.h"
#include "ttokendef.h"
#include "qast.h"
TAOS
*
taos_connect_imp
(
const
char
*
ip
,
const
char
*
user
,
const
char
*
pass
,
const
char
*
db
,
uint16_t
port
,
void
(
*
fp
)(
void
*
,
TAOS_RES
*
,
int
),
void
*
param
,
void
**
taos
)
{
...
...
src/client/src/tscUtil.c
浏览文件 @
0cd2043c
...
...
@@ -16,8 +16,8 @@
#include "tscUtil.h"
#include "hash.h"
#include "os.h"
#include "qast.h"
#include "taosmsg.h"
#include "tast.h"
#include "tcache.h"
#include "tkey.h"
#include "tmd5.h"
...
...
src/mnode/src/mgmtTable.c
浏览文件 @
0cd2043c
...
...
@@ -30,10 +30,10 @@
#include "mgmtVgroup.h"
#include "mnode.h"
#include "os.h"
#include "qast.h"
#include "qextbuffer.h"
#include "taoserror.h"
#include "taosmsg.h"
#include "tast.h"
#include "tschemautil.h"
#include "tscompression.h"
#include "tskiplist.h"
...
...
src/query/inc/
t
ast.h
→
src/query/inc/
q
ast.h
浏览文件 @
0cd2043c
文件已移动
src/query/inc/qextbuffer.h
浏览文件 @
0cd2043c
...
...
@@ -131,13 +131,6 @@ typedef struct tSidSet {
SColumnOrderInfo
orderIdx
;
}
tSidSet
;
/**
*
* @param fileNamePattern
* @param dstPath
*/
void
getTmpfilePath
(
const
char
*
fileNamePattern
,
char
*
dstPath
);
/**
*
* @param inMemSize
...
...
src/query/inc/qtsbuf.h
0 → 100644
浏览文件 @
0cd2043c
/*
* Copyright (c) 2019 TAOS Data, Inc. <jhtao@taosdata.com>
*
* This program is free software: you can use, redistribute, and/or modify
* it under the terms of the GNU Affero General Public License, version 3
* or later ("AGPL"), as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef TDENGINE_STSBUF_H
#define TDENGINE_STSBUF_H
#ifdef __cplusplus
extern
"C"
{
#endif
#include "os.h"
#include "taosdef.h"
#define MEM_BUF_SIZE (1 << 20)
#define TS_COMP_FILE_MAGIC 0x87F5EC4C
#define TS_COMP_FILE_VNODE_MAX 512
typedef
struct
STSList
{
char
*
rawBuf
;
int32_t
allocSize
;
int32_t
threshold
;
int32_t
len
;
}
STSList
;
typedef
struct
STSRawBlock
{
int32_t
vnode
;
int64_t
tag
;
TSKEY
*
ts
;
int32_t
len
;
}
STSRawBlock
;
typedef
struct
STSElem
{
TSKEY
ts
;
int64_t
tag
;
int32_t
vnode
;
}
STSElem
;
typedef
struct
STSCursor
{
int32_t
vnodeIndex
;
int32_t
blockIndex
;
int32_t
tsIndex
;
int32_t
order
;
}
STSCursor
;
typedef
struct
STSBlock
{
int64_t
tag
;
// tag value
int32_t
numOfElem
;
// number of elements
int32_t
compLen
;
// size after compressed
int32_t
padding
;
// 0xFFFFFFFF by default, after the payload
char
*
payload
;
// actual data that is compressed
}
STSBlock
;
/*
* The size of buffer file should not be greater than 2G,
* and the offset of int32_t type is enough
*/
typedef
struct
STSVnodeBlockInfo
{
int32_t
vnode
;
// vnode id
int32_t
offset
;
// offset set value in file
int32_t
numOfBlocks
;
// number of total blocks
int32_t
compLen
;
// compressed size
}
STSVnodeBlockInfo
;
typedef
struct
STSVnodeBlockInfoEx
{
STSVnodeBlockInfo
info
;
int32_t
len
;
// length before compress
}
STSVnodeBlockInfoEx
;
typedef
struct
STSBuf
{
FILE
*
f
;
char
path
[
PATH_MAX
];
uint32_t
fileSize
;
STSVnodeBlockInfoEx
*
pData
;
int32_t
numOfAlloc
;
int32_t
numOfVnodes
;
char
*
assistBuf
;
int32_t
bufSize
;
STSBlock
block
;
STSList
tsData
;
// uncompressed raw ts data
uint64_t
numOfTotal
;
bool
autoDelete
;
int32_t
tsOrder
;
// order of timestamp in ts comp buffer
STSCursor
cur
;
}
STSBuf
;
typedef
struct
STSBufFileHeader
{
uint32_t
magic
;
// file magic number
uint32_t
numOfVnode
;
// number of vnode stored in current file
uint32_t
tsOrder
;
// timestamp order in current file
}
STSBufFileHeader
;
STSBuf
*
tsBufCreate
(
bool
autoDelete
);
STSBuf
*
tsBufCreateFromFile
(
const
char
*
path
,
bool
autoDelete
);
STSBuf
*
tsBufCreateFromCompBlocks
(
const
char
*
pData
,
int32_t
numOfBlocks
,
int32_t
len
,
int32_t
tsOrder
);
void
*
tsBufDestory
(
STSBuf
*
pTSBuf
);
void
tsBufAppend
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
,
int64_t
tag
,
const
char
*
pData
,
int32_t
len
);
int32_t
tsBufMerge
(
STSBuf
*
pDestBuf
,
const
STSBuf
*
pSrcBuf
,
int32_t
vnodeIdx
);
STSBuf
*
tsBufClone
(
STSBuf
*
pTSBuf
);
STSVnodeBlockInfo
*
tsBufGetVnodeBlockInfo
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
);
void
tsBufFlush
(
STSBuf
*
pTSBuf
);
void
tsBufResetPos
(
STSBuf
*
pTSBuf
);
STSElem
tsBufGetElem
(
STSBuf
*
pTSBuf
);
bool
tsBufNextPos
(
STSBuf
*
pTSBuf
);
STSElem
tsBufGetElemStartPos
(
STSBuf
*
pTSBuf
,
int32_t
vnodeId
,
int64_t
tag
);
STSCursor
tsBufGetCursor
(
STSBuf
*
pTSBuf
);
void
tsBufSetTraverseOrder
(
STSBuf
*
pTSBuf
,
int32_t
order
);
void
tsBufSetCursor
(
STSBuf
*
pTSBuf
,
STSCursor
*
pCur
);
/**
* display all data in comp block file, for debug purpose only
* @param pTSBuf
*/
void
tsBufDisplay
(
STSBuf
*
pTSBuf
);
#ifdef __cplusplus
}
#endif
#endif // TDENGINE_STSBUF_H
src/query/src/qast.c
浏览文件 @
0cd2043c
...
...
@@ -13,12 +13,12 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "qast.h"
#include "os.h"
#include "qsqlparser.h"
#include "qsyntaxtreefunction.h"
#include "taosdef.h"
#include "taosmsg.h"
#include "tast.h"
#include "tlog.h"
#include "tschemautil.h"
#include "tsqlfunction.h"
...
...
@@ -608,6 +608,7 @@ int32_t merge(tQueryResultset *pLeft, tQueryResultset *pRight, tQueryResultset *
// }
//
// return pFinalRes->num;
return
0
;
}
int32_t
intersect
(
tQueryResultset
*
pLeft
,
tQueryResultset
*
pRight
,
tQueryResultset
*
pFinalRes
)
{
...
...
@@ -642,6 +643,7 @@ int32_t intersect(tQueryResultset *pLeft, tQueryResultset *pRight, tQueryResults
// }
//
// return pFinalRes->num;
return
0
;
}
/*
...
...
src/query/src/qextbuffer.c
浏览文件 @
0cd2043c
...
...
@@ -25,29 +25,6 @@
#define COLMODEL_GET_VAL(data, schema, allrow, rowId, colId) \
(data + (schema)->pFields[colId].offset * (allrow) + (rowId) * (schema)->pFields[colId].field.bytes)
int32_t
tmpFileSerialNum
=
0
;
void
getTmpfilePath
(
const
char
*
fileNamePrefix
,
char
*
dstPath
)
{
const
char
*
tdengineTmpFileNamePrefix
=
"tdengine-"
;
char
tmpPath
[
MAX_TMPFILE_PATH_LENGTH
]
=
{
0
};
#ifdef WINDOWS
char
*
tmpDir
=
getenv
(
"tmp"
);
if
(
tmpDir
==
NULL
)
{
tmpDir
=
""
;
}
#else
char
*
tmpDir
=
"/tmp/"
;
#endif
strcpy
(
tmpPath
,
tmpDir
);
strcat
(
tmpPath
,
tdengineTmpFileNamePrefix
);
strcat
(
tmpPath
,
fileNamePrefix
);
strcat
(
tmpPath
,
"-%llu-%u"
);
snprintf
(
dstPath
,
MAX_TMPFILE_PATH_LENGTH
,
tmpPath
,
taosGetPthreadId
(),
atomic_add_fetch_32
(
&
tmpFileSerialNum
,
1
));
}
/*
* SColumnModel is deeply copy
*/
...
...
src/query/src/qtsbuf.c
0 → 100644
浏览文件 @
0cd2043c
此差异已折叠。
点击以展开。
src/util/inc/tutil.h
浏览文件 @
0cd2043c
...
...
@@ -137,6 +137,13 @@ int64_t str2int64(char *str);
int32_t
taosFileRename
(
char
*
fullPath
,
char
*
suffix
,
char
delimiter
,
char
**
dstPath
);
/**
*
* @param fileNamePattern
* @param dstPath
*/
void
getTmpfilePath
(
const
char
*
fileNamePattern
,
char
*
dstPath
);
int32_t
taosInitTimer
(
void
(
*
callback
)(
int
),
int32_t
ms
);
bool
taosMbsToUcs4
(
char
*
mbs
,
int32_t
mbs_len
,
char
*
ucs4
,
int32_t
ucs4_max_len
);
...
...
src/util/src/hash.c
浏览文件 @
0cd2043c
...
...
@@ -520,6 +520,7 @@ SHashMutableIterator *taosHashCreateIter(SHashObj *pHashObj) {
}
pIter
->
pHashObj
=
pHashObj
;
return
pIter
;
}
static
SHashNode
*
getNextHashNode
(
SHashMutableIterator
*
pIter
)
{
...
...
@@ -600,6 +601,7 @@ void *taosHashDestroyIter(SHashMutableIterator *iter) {
}
free
(
iter
);
return
NULL
;
}
// for profile only
...
...
src/util/src/tutil.c
浏览文件 @
0cd2043c
...
...
@@ -27,6 +27,8 @@
#include "tlog.h"
#include "taoserror.h"
int32_t
tmpFileSerialNum
=
0
;
int32_t
strdequote
(
char
*
z
)
{
if
(
z
==
NULL
)
{
return
0
;
...
...
@@ -401,6 +403,27 @@ int32_t taosFileRename(char *fullPath, char *suffix, char delimiter, char **dstP
return
rename
(
fullPath
,
*
dstPath
);
}
void
getTmpfilePath
(
const
char
*
fileNamePrefix
,
char
*
dstPath
)
{
const
char
*
tdengineTmpFileNamePrefix
=
"tdengine-"
;
char
tmpPath
[
PATH_MAX
]
=
{
0
};
#ifdef WINDOWS
char
*
tmpDir
=
getenv
(
"tmp"
);
if
(
tmpDir
==
NULL
)
{
tmpDir
=
""
;
}
#else
char
*
tmpDir
=
"/tmp/"
;
#endif
strcpy
(
tmpPath
,
tmpDir
);
strcat
(
tmpPath
,
tdengineTmpFileNamePrefix
);
strcat
(
tmpPath
,
fileNamePrefix
);
strcat
(
tmpPath
,
"-%llu-%u"
);
snprintf
(
dstPath
,
PATH_MAX
,
tmpPath
,
taosGetPthreadId
(),
atomic_add_fetch_32
(
&
tmpFileSerialNum
,
1
));
}
int
tasoUcs4Compare
(
void
*
f1_ucs4
,
void
*
f2_ucs4
,
int
bytes
)
{
#if defined WINDOWS
for
(
int
i
=
0
;
i
<
bytes
;
++
i
)
{
...
...
src/vnode/detail/inc/vnodeSupertableQuery.h
浏览文件 @
0cd2043c
...
...
@@ -16,11 +16,9 @@
#ifndef TBASE_MNODE_SUPER_TABLE_QUERY_H
#define TBASE_MNODE_SUPER_TABLE_QUERY_H
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include "os.h"
#include "mnode.h"
#include "
t
ast.h"
#include "
q
ast.h"
int32_t
mgmtDoJoin
(
SSuperTableMetaMsg
*
pSuperTableMetaMsg
,
tQueryResultset
*
pRes
);
void
mgmtReorganizeMetersInMetricMeta
(
SSuperTableMetaMsg
*
pInfo
,
int32_t
index
,
tQueryResultset
*
pRes
);
...
...
src/vnode/detail/src/vnodeRead.c
浏览文件 @
0cd2043c
...
...
@@ -19,9 +19,9 @@
#include "hash.h"
#include "hashfunc.h"
#include "ihash.h"
#include "qast.h"
#include "qextbuffer.h"
#include "taosmsg.h"
#include "tast.h"
#include "tscJoinProcess.h"
#include "tscompression.h"
#include "vnode.h"
...
...
src/vnode/detail/src/vnodeSupertableQuery.c
浏览文件 @
0cd2043c
...
...
@@ -16,11 +16,10 @@
#define _DEFAULT_SOURCE
#include "mnode.h"
#include "os.h"
#include "qast.h"
#include "qextbuffer.h"
#include "tast.h"
#include "tschemautil.h"
#include "tsqlfunction.h"
//#include "vnodeTagMgmt.h"
typedef
struct
SSyntaxTreeFilterSupporter
{
SSchema
*
pTagSchema
;
...
...
src/vnode/detail/src/vnodeTagMgmt.c
浏览文件 @
0cd2043c
...
...
@@ -16,10 +16,10 @@
#define _DEFAULT_SOURCE
#include "os.h"
#include "qast.h"
#include "qextbuffer.h"
#include "taosdef.h"
#include "taosmsg.h"
#include "tast.h"
#include "tlog.h"
#include "tutil.h"
#include "vnodeTagMgmt.h"
...
...
src/vnode/detail/src/vnodeUtil.c
浏览文件 @
0cd2043c
...
...
@@ -16,13 +16,13 @@
#define _DEFAULT_SOURCE
#include "os.h"
#include "
t
ast.h"
#include "
q
ast.h"
#include "tscUtil.h"
#include "tschemautil.h"
#include "vnode.h"
#include "vnodeDataFilterFunc.h"
#include "vnodeUtil.h"
#include "vnodeStatus.h"
#include "vnodeUtil.h"
int
vnodeCheckFileIntegrity
(
FILE
*
fp
)
{
/*
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录