Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
98be150f
T
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1185
Star
22015
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看板
提交
98be150f
编写于
3月 03, 2020
作者:
H
hzcheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
more
上级
a92a1f12
变更
6
显示空白变更内容
内联
并排
Showing
6 changed file
with
119 addition
and
12 deletion
+119
-12
src/dnode/CMakeLists.txt
src/dnode/CMakeLists.txt
+1
-1
src/vnode/common/inc/dataformat.h
src/vnode/common/inc/dataformat.h
+21
-0
src/vnode/tsdb/inc/tsdb.h
src/vnode/tsdb/inc/tsdb.h
+22
-3
src/vnode/tsdb/inc/tsdbCache.h
src/vnode/tsdb/inc/tsdbCache.h
+22
-0
src/vnode/tsdb/inc/tsdbFile.h
src/vnode/tsdb/inc/tsdbFile.h
+22
-0
src/vnode/tsdb/inc/tsdbMeta.h
src/vnode/tsdb/inc/tsdbMeta.h
+31
-8
未找到文件。
src/dnode/CMakeLists.txt
浏览文件 @
98be150f
...
...
@@ -10,7 +10,7 @@ IF ((TD_LINUX_64) OR (TD_LINUX_32 AND TD_ARM))
AUX_SOURCE_DIRECTORY
(
src SRC
)
ADD_EXECUTABLE
(
taosd
${
SRC
}
)
TARGET_LINK_LIBRARIES
(
taosd mnode sdb taos_static monitor http
)
TARGET_LINK_LIBRARIES
(
taosd mnode sdb taos_static monitor http
tsdb
)
#IF (TD_CLUSTER)
# TARGET_LINK_LIBRARIES(taosd dcluster)
...
...
src/vnode/common/inc/dataformat.h
浏览文件 @
98be150f
/*
* 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/>.
*/
#if !defined(_TD_DATA_FORMAT_H_)
#define _TD_DATA_FORMAT_H_
...
...
@@ -5,6 +19,9 @@
#include "schema.h"
#ifdef __cplusplus
extern
"C"
{
#endif
// ----------------- Data row structure
/* A data row, the format of it is like below:
...
...
@@ -71,4 +88,8 @@ SDataRow tdSDataRowDup(SDataRow rdata);
*/
int32_t
tdGetMaxDataRowSize
(
SSchema
*
pSchema
);
#ifdef __cplusplus
}
#endif
#endif // _TD_DATA_FORMAT_H_
src/vnode/tsdb/inc/tsdb.h
浏览文件 @
98be150f
/**************************************
* FOR OUTSIDE USAGE
**************************************/
/*
* 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/>.
*/
#if !defined(_TD_TSDB_H_)
#define _TD_TSDB_H_
...
...
@@ -11,6 +22,10 @@
#include "dataformat.h"
#include "schema.h"
#ifdef __cplusplus
extern
"C"
{
#endif
#define TSDB_VERSION_MAJOR 1
#define TSDB_VERSION_MINOR 0
...
...
@@ -324,4 +339,8 @@ STableIDList *tsdbGetTableList(tsdb_query_handle_t *pQueryHandle);
*/
STableIDList
*
tsdbQueryTableList
(
int16_t
stableId
,
const
char
*
pTagCond
);
#ifdef __cplusplus
}
#endif
#endif // _TD_TSDB_H_
\ No newline at end of file
src/vnode/tsdb/inc/tsdbCache.h
浏览文件 @
98be150f
/*
* 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/>.
*/
#if !defined(_TD_TSDBCACHE_H_)
#define _TD_TSDBCACHE_H_
...
...
@@ -5,6 +19,10 @@
// #include "cache.h"
#ifdef __cplusplus
extern
"C"
{
#endif
#define TSDB_DEFAULT_CACHE_BLOCK_SIZE 16*1024*1024
/* 16M */
typedef
struct
{
...
...
@@ -38,4 +56,8 @@ typedef struct STSDBCache {
SCacheHandle
*
tsdbCreateCache
(
int32_t
numOfBlocks
);
int32_t
tsdbFreeCache
(
SCacheHandle
*
pHandle
);
#ifdef __cplusplus
}
#endif
#endif // _TD_TSDBCACHE_H_
src/vnode/tsdb/inc/tsdbFile.h
浏览文件 @
98be150f
/*
* 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/>.
*/
#if !defined(_TD_TSDB_FILE_H_)
#define _TD_TSDB_FILE_H_
#include <stdint.h>
// #include "tstring.h"
#ifdef __cplusplus
extern
"C"
{
#endif
typedef
int32_t
file_id_t
;
typedef
enum
{
...
...
@@ -38,4 +56,8 @@ typedef struct {
char
*
tsdbGetFileName
(
char
*
dirName
,
char
*
fname
,
TSDB_FILE_TYPE
type
);
#ifdef __cplusplus
}
#endif
#endif // _TD_TSDB_FILE_H_
src/vnode/tsdb/inc/tsdbMeta.h
浏览文件 @
98be150f
/************************************
* For internal usage
************************************/
/*
* 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/>.
*/
#if !defined(_TSDB_META_H_)
#define _TSDB_META_H_
#include <pthread.h>
#include "dataformat.h"
#ifdef __cplusplus
extern
"C"
{
#endif
// #include "taosdef.h"
// Initially, there are 4 tables
...
...
@@ -59,7 +76,7 @@ typedef struct STable {
typedef
struct
{
int32_t
maxTables
;
STable
**
tables
;
// array of normal tables
STable
**
tables
;
// array of normal tables
STable
*
stables
;
// linked list of super tables
void
*
tableMap
;
// hash map of uid ==> STable *
}
STsdbMeta
;
...
...
@@ -93,3 +110,9 @@ STsdbMeta *tsdbOpenMetaHandle(char *tsdbDir);
int32_t
tsdbCreateTableImpl
(
STsdbMeta
*
pHandle
,
STableCfg
*
pCfg
);
int32_t
tsdbInsertDataImpl
(
STsdbMeta
*
pMeta
,
STableId
tableId
,
char
*
pData
);
#ifdef __cplusplus
}
#endif
#endif // _TSDB_META_H_
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录