Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
54e1f69d
TDengine
项目概览
taosdata
/
TDengine
9 个月 前同步成功
通知
1176
Star
22014
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看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
未验证
提交
54e1f69d
编写于
8月 21, 2023
作者:
W
wade zhang
提交者:
GitHub
8月 21, 2023
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #22481 from taosdata/fix/TD-25822
enh(tsdb/write): timestamp out of range with s3's last tier storage
上级
b7084933
c4a3a5da
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
24 addition
and
2 deletion
+24
-2
source/dnode/vnode/src/tsdb/tsdbWrite.c
source/dnode/vnode/src/tsdb/tsdbWrite.c
+11
-1
source/dnode/vnode/src/vnd/vnodeSvr.c
source/dnode/vnode/src/vnd/vnodeSvr.c
+13
-1
未找到文件。
source/dnode/vnode/src/tsdb/tsdbWrite.c
浏览文件 @
54e1f69d
...
...
@@ -14,6 +14,7 @@
*/
#include "tsdb.h"
#include "vndCos.h"
/**
* @brief max key by precision
...
...
@@ -76,9 +77,18 @@ int tsdbScanAndConvertSubmitMsg(STsdb *pTsdb, SSubmitReq2 *pMsg) {
int32_t
code
=
0
;
STsdbKeepCfg
*
pCfg
=
&
pTsdb
->
keepCfg
;
TSKEY
now
=
taosGetTimestamp
(
pCfg
->
precision
);
TSKEY
minKey
=
now
-
tsTickPerMin
[
pCfg
->
precision
]
*
pCfg
->
keep
1
;
TSKEY
minKey
=
now
-
tsTickPerMin
[
pCfg
->
precision
]
*
pCfg
->
keep
2
;
TSKEY
maxKey
=
tsMaxKeyByPrecision
[
pCfg
->
precision
];
int32_t
size
=
taosArrayGetSize
(
pMsg
->
aSubmitTbData
);
int32_t
nlevel
=
tfsGetLevel
(
pTsdb
->
pVnode
->
pTfs
);
if
(
nlevel
>
1
&&
tsS3Enabled
)
{
if
(
nlevel
==
3
)
{
minKey
=
now
-
tsTickPerMin
[
pCfg
->
precision
]
*
pCfg
->
keep1
;
}
else
if
(
nlevel
==
2
)
{
minKey
=
now
-
tsTickPerMin
[
pCfg
->
precision
]
*
pCfg
->
keep0
;
}
}
for
(
int32_t
i
=
0
;
i
<
size
;
++
i
)
{
SSubmitTbData
*
pData
=
TARRAY_GET_ELEM
(
pMsg
->
aSubmitTbData
,
i
);
...
...
source/dnode/vnode/src/vnd/vnodeSvr.c
浏览文件 @
54e1f69d
...
...
@@ -16,6 +16,7 @@
#include "tencode.h"
#include "tmsg.h"
#include "vnd.h"
#include "vndCos.h"
#include "vnode.h"
#include "vnodeInt.h"
...
...
@@ -190,7 +191,18 @@ static int32_t vnodePreProcessSubmitTbData(SVnode *pVnode, SDecoder *pCoder, int
}
else
if
(
pVnode
->
config
.
tsdbCfg
.
precision
==
TSDB_TIME_PRECISION_NANO
)
{
now
*=
1000000
;
}
TSKEY
minKey
=
now
-
tsTickPerMin
[
pVnode
->
config
.
tsdbCfg
.
precision
]
*
pVnode
->
config
.
tsdbCfg
.
keep2
;
int32_t
nlevel
=
tfsGetLevel
(
pVnode
->
pTfs
);
int32_t
keep
=
pVnode
->
config
.
tsdbCfg
.
keep2
;
if
(
nlevel
>
1
&&
tsS3Enabled
)
{
if
(
nlevel
==
3
)
{
keep
=
pVnode
->
config
.
tsdbCfg
.
keep1
;
}
else
if
(
nlevel
==
2
)
{
keep
=
pVnode
->
config
.
tsdbCfg
.
keep0
;
}
}
TSKEY
minKey
=
now
-
tsTickPerMin
[
pVnode
->
config
.
tsdbCfg
.
precision
]
*
keep
;
TSKEY
maxKey
=
tsMaxKeyByPrecision
[
pVnode
->
config
.
tsdbCfg
.
precision
];
if
(
submitTbData
.
flags
&
SUBMIT_REQ_COLUMN_DATA_FORMAT
)
{
uint64_t
nColData
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录