Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
10b8756c
TDengine
项目概览
taosdata
/
TDengine
大约 2 年 前同步成功
通知
1193
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看板
提交
10b8756c
编写于
4月 14, 2022
作者:
H
Hongze Cheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
refact vnode
上级
272d0ec7
变更
2
显示空白变更内容
内联
并排
Showing
2 changed file
with
17 addition
and
71 deletion
+17
-71
source/dnode/vnode/inc/vnode.h
source/dnode/vnode/inc/vnode.h
+17
-66
source/dnode/vnode/src/meta/metaCfg.c
source/dnode/vnode/src/meta/metaCfg.c
+0
-5
未找到文件。
source/dnode/vnode/inc/vnode.h
浏览文件 @
10b8756c
...
@@ -110,7 +110,16 @@ typedef void *tsdbReaderT;
...
@@ -110,7 +110,16 @@ typedef void *tsdbReaderT;
#define BLOCK_LOAD_TABLE_RR_ORDER 3
#define BLOCK_LOAD_TABLE_RR_ORDER 3
#define TABLE_TID(t) (t)->tid
#define TABLE_TID(t) (t)->tid
#define TABLE_UID(t) (t)->uid
#define TABLE_UID(t) (t)->uid
STsdb
*
tsdbOpen
(
const
char
*
path
,
int32_t
vgId
,
const
STsdbCfg
*
pTsdbCfg
,
SMemAllocatorFactory
*
pMAF
,
SMeta
*
pMeta
,
STfs
*
pTfs
);
void
tsdbClose
(
STsdb
*
);
void
tsdbRemove
(
const
char
*
path
);
int
tsdbInsertData
(
STsdb
*
pTsdb
,
SSubmitReq
*
pMsg
,
SSubmitRsp
*
pRsp
);
int
tsdbPrepareCommit
(
STsdb
*
pTsdb
);
int
tsdbCommit
(
STsdb
*
pTsdb
);
int32_t
tsdbInitSma
(
STsdb
*
pTsdb
);
int32_t
tsdbCreateTSma
(
STsdb
*
pTsdb
,
char
*
pMsg
);
int32_t
tsdbDropTSma
(
STsdb
*
pTsdb
,
char
*
pMsg
);
tsdbReaderT
*
tsdbQueryTables
(
STsdb
*
tsdb
,
STsdbQueryCond
*
pCond
,
STableGroupInfo
*
tableInfoGroup
,
uint64_t
qId
,
tsdbReaderT
*
tsdbQueryTables
(
STsdb
*
tsdb
,
STsdbQueryCond
*
pCond
,
STableGroupInfo
*
tableInfoGroup
,
uint64_t
qId
,
uint64_t
taskId
);
uint64_t
taskId
);
tsdbReaderT
tsdbQueryCacheLast
(
STsdb
*
tsdb
,
STsdbQueryCond
*
pCond
,
STableGroupInfo
*
groupList
,
uint64_t
qId
,
tsdbReaderT
tsdbQueryCacheLast
(
STsdb
*
tsdb
,
STsdbQueryCond
*
pCond
,
STableGroupInfo
*
groupList
,
uint64_t
qId
,
...
@@ -129,6 +138,10 @@ void tsdbDestroyTableGroup(STableGroupInfo *pGroupList);
...
@@ -129,6 +138,10 @@ void tsdbDestroyTableGroup(STableGroupInfo *pGroupList);
int32_t
tsdbGetOneTableGroup
(
void
*
pMeta
,
uint64_t
uid
,
TSKEY
startKey
,
STableGroupInfo
*
pGroupInfo
);
int32_t
tsdbGetOneTableGroup
(
void
*
pMeta
,
uint64_t
uid
,
TSKEY
startKey
,
STableGroupInfo
*
pGroupInfo
);
int32_t
tsdbGetTableGroupFromIdList
(
STsdb
*
tsdb
,
SArray
*
pTableIdList
,
STableGroupInfo
*
pGroupInfo
);
int32_t
tsdbGetTableGroupFromIdList
(
STsdb
*
tsdb
,
SArray
*
pTableIdList
,
STableGroupInfo
*
pGroupInfo
);
void
tsdbCleanupReadHandle
(
tsdbReaderT
queryHandle
);
void
tsdbCleanupReadHandle
(
tsdbReaderT
queryHandle
);
int32_t
tsdbUpdateSmaWindow
(
STsdb
*
pTsdb
,
SSubmitReq
*
pMsg
,
int64_t
version
);
int32_t
tsdbInsertTSmaData
(
STsdb
*
pTsdb
,
int64_t
indexUid
,
const
char
*
msg
);
int32_t
tsdbDropTSmaData
(
STsdb
*
pTsdb
,
int64_t
indexUid
);
int32_t
tsdbInsertRSmaData
(
STsdb
*
pTsdb
,
char
*
msg
);
// tq
// tq
enum
{
enum
{
...
@@ -149,7 +162,9 @@ bool tqNextDataBlock(STqReadHandle *pHandle);
...
@@ -149,7 +162,9 @@ bool tqNextDataBlock(STqReadHandle *pHandle);
int
tqRetrieveDataBlockInfo
(
STqReadHandle
*
pHandle
,
SDataBlockInfo
*
pBlockInfo
);
int
tqRetrieveDataBlockInfo
(
STqReadHandle
*
pHandle
,
SDataBlockInfo
*
pBlockInfo
);
SArray
*
tqRetrieveDataBlock
(
STqReadHandle
*
pHandle
);
SArray
*
tqRetrieveDataBlock
(
STqReadHandle
*
pHandle
);
// need to remove
// need to reposition
typedef
struct
SMgmtWrapper
SMgmtWrapper
;
int32_t
tdScanAndConvertSubmitMsg
(
SSubmitReq
*
pMsg
);
int32_t
tdScanAndConvertSubmitMsg
(
SSubmitReq
*
pMsg
);
// structs
// structs
...
@@ -212,11 +227,6 @@ struct STqReadHandle {
...
@@ -212,11 +227,6 @@ struct STqReadHandle {
STSchema
*
pSchema
;
STSchema
*
pSchema
;
};
};
// ---------------------------- OLD ----------------------------
typedef
struct
SMgmtWrapper
SMgmtWrapper
;
// Types exported
struct
SDataStatis
{
struct
SDataStatis
{
int16_t
colId
;
int16_t
colId
;
int16_t
maxIndex
;
int16_t
maxIndex
;
...
@@ -247,8 +257,6 @@ typedef struct STable {
...
@@ -247,8 +257,6 @@ typedef struct STable {
STSchema
*
pSchema
;
STSchema
*
pSchema
;
}
STable
;
}
STable
;
/* ------------------------ FOR COMPILE ------------------------ */
typedef
struct
{
typedef
struct
{
int8_t
type
;
int8_t
type
;
int8_t
reserved
[
7
];
int8_t
reserved
[
7
];
...
@@ -259,63 +267,6 @@ typedef struct {
...
@@ -259,63 +267,6 @@ typedef struct {
};
};
}
STqStreamToken
;
}
STqStreamToken
;
// meta.h
// Options
void
metaOptionsInit
(
SMetaCfg
*
pMetaCfg
);
void
metaOptionsClear
(
SMetaCfg
*
pMetaCfg
);
// query condition to build multi-table data block iterator
// STsdb
STsdb
*
tsdbOpen
(
const
char
*
path
,
int32_t
vgId
,
const
STsdbCfg
*
pTsdbCfg
,
SMemAllocatorFactory
*
pMAF
,
SMeta
*
pMeta
,
STfs
*
pTfs
);
void
tsdbClose
(
STsdb
*
);
void
tsdbRemove
(
const
char
*
path
);
int
tsdbInsertData
(
STsdb
*
pTsdb
,
SSubmitReq
*
pMsg
,
SSubmitRsp
*
pRsp
);
int
tsdbPrepareCommit
(
STsdb
*
pTsdb
);
int
tsdbCommit
(
STsdb
*
pTsdb
);
int32_t
tsdbInitSma
(
STsdb
*
pTsdb
);
int32_t
tsdbCreateTSma
(
STsdb
*
pTsdb
,
char
*
pMsg
);
int32_t
tsdbDropTSma
(
STsdb
*
pTsdb
,
char
*
pMsg
);
/**
* @brief When submit msg received, update the relative expired window synchronously.
*
* @param pTsdb
* @param pMsg
* @param version
* @return int32_t
*/
int32_t
tsdbUpdateSmaWindow
(
STsdb
*
pTsdb
,
SSubmitReq
*
pMsg
,
int64_t
version
);
/**
* @brief Insert tSma(Time-range-wise SMA) data from stream computing engine
*
* @param pTsdb
* @param indexUid
* @param msg
* @return int32_t
*/
int32_t
tsdbInsertTSmaData
(
STsdb
*
pTsdb
,
int64_t
indexUid
,
const
char
*
msg
);
/**
* @brief Drop tSma data and local cache.
*
* @param pTsdb
* @param indexUid
* @return int32_t
*/
int32_t
tsdbDropTSmaData
(
STsdb
*
pTsdb
,
int64_t
indexUid
);
/**
* @brief Insert RSma(Rollup SMA) data.
*
* @param pTsdb
* @param msg
* @return int32_t
*/
int32_t
tsdbInsertRSmaData
(
STsdb
*
pTsdb
,
char
*
msg
);
#ifdef __cplusplus
#ifdef __cplusplus
}
}
#endif
#endif
...
...
source/dnode/vnode/src/meta/metaCfg.c
浏览文件 @
10b8756c
...
@@ -18,11 +18,6 @@
...
@@ -18,11 +18,6 @@
const
SMetaCfg
defaultMetaOptions
=
{.
lruSize
=
0
};
const
SMetaCfg
defaultMetaOptions
=
{.
lruSize
=
0
};
/* ------------------------ EXPOSED METHODS ------------------------ */
/* ------------------------ EXPOSED METHODS ------------------------ */
void
metaOptionsInit
(
SMetaCfg
*
pMetaOptions
)
{
metaOptionsCopy
(
pMetaOptions
,
&
defaultMetaOptions
);
}
void
metaOptionsClear
(
SMetaCfg
*
pMetaOptions
)
{
// TODO
}
int
metaValidateOptions
(
const
SMetaCfg
*
pMetaOptions
)
{
int
metaValidateOptions
(
const
SMetaCfg
*
pMetaOptions
)
{
// TODO
// TODO
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录