Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
bea199ce
T
TDengine
项目概览
taosdata
/
TDengine
大约 1 年 前同步成功
通知
1184
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看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
bea199ce
编写于
7月 23, 2021
作者:
H
Hongze Cheng
提交者:
GitHub
7月 23, 2021
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #6981 from taosdata/compress_float
change config name in taos.cfg
上级
868daf4f
1393637d
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
13 addition
and
9 deletion
+13
-9
src/common/inc/tglobal.h
src/common/inc/tglobal.h
+2
-2
src/common/src/tglobal.c
src/common/src/tglobal.c
+6
-6
src/mnode/src/mnodeDnode.c
src/mnode/src/mnodeDnode.c
+1
-0
src/util/src/tcompression.c
src/util/src/tcompression.c
+1
-1
src/util/src/tconfig.c
src/util/src/tconfig.c
+3
-0
未找到文件。
src/common/inc/tglobal.h
浏览文件 @
bea199ce
...
...
@@ -210,8 +210,8 @@ extern int32_t debugFlag;
extern
char
lossyColumns
[];
extern
double
fPrecision
;
extern
double
dPrecision
;
extern
uint32_t
max
Intervals
;
extern
uint32_t
intervals
;
extern
uint32_t
max
Range
;
extern
uint32_t
curRange
;
extern
char
Compressor
[];
#endif
...
...
src/common/src/tglobal.c
浏览文件 @
bea199ce
...
...
@@ -252,8 +252,8 @@ char lossyColumns[32] = ""; // "float|double" means all float and double column
// below option can take effect when tsLossyColumns not empty
double
fPrecision
=
1E-8
;
// float column precision
double
dPrecision
=
1E-16
;
// double column precision
uint32_t
max
Intervals
=
500
;
// max intervals
uint32_t
intervals
=
100
;
// intervals
uint32_t
max
Range
=
500
;
// max range
uint32_t
curRange
=
100
;
// range
char
Compressor
[
32
]
=
"ZSTD_COMPRESSOR"
;
// ZSTD_COMPRESSOR or GZIP_COMPRESSOR
#endif
...
...
@@ -1565,8 +1565,8 @@ static void doInitGlobalConfig(void) {
cfg
.
unitType
=
TAOS_CFG_UTYPE_NONE
;
taosInitConfigOption
(
cfg
);
cfg
.
option
=
"max
Intervals
"
;
cfg
.
ptr
=
&
max
Intervals
;
cfg
.
option
=
"max
Range
"
;
cfg
.
ptr
=
&
max
Range
;
cfg
.
valType
=
TAOS_CFG_VTYPE_INT32
;
cfg
.
cfgType
=
TSDB_CFG_CTYPE_B_CONFIG
;
cfg
.
minValue
=
0
;
...
...
@@ -1575,8 +1575,8 @@ static void doInitGlobalConfig(void) {
cfg
.
unitType
=
TAOS_CFG_UTYPE_NONE
;
taosInitConfigOption
(
cfg
);
cfg
.
option
=
"
intervals
"
;
cfg
.
ptr
=
&
intervals
;
cfg
.
option
=
"
range
"
;
cfg
.
ptr
=
&
curRange
;
cfg
.
valType
=
TAOS_CFG_VTYPE_INT32
;
cfg
.
cfgType
=
TSDB_CFG_CTYPE_B_CONFIG
;
cfg
.
minValue
=
0
;
...
...
src/mnode/src/mnodeDnode.c
浏览文件 @
bea199ce
...
...
@@ -1146,6 +1146,7 @@ static int32_t mnodeRetrieveConfigs(SShowObj *pShow, char *data, int32_t rows, v
numOfRows
++
;
break
;
case
TAOS_CFG_VTYPE_FLOAT
:
case
TAOS_CFG_VTYPE_DOUBLE
:
t
=
snprintf
(
varDataVal
(
pWrite
),
TSDB_CFG_VALUE_LEN
,
"%f"
,
*
((
float
*
)
cfg
->
ptr
));
varDataSetLen
(
pWrite
,
t
);
numOfRows
++
;
...
...
src/util/src/tcompression.c
浏览文件 @
bea199ce
...
...
@@ -85,7 +85,7 @@ int tsCompressInit(){
if
(
lossyFloat
==
false
&&
lossyDouble
==
false
)
return
0
;
tdszInit
(
fPrecision
,
dPrecision
,
max
Intervals
,
intervals
,
Compressor
);
tdszInit
(
fPrecision
,
dPrecision
,
max
Range
,
curRange
,
Compressor
);
if
(
lossyFloat
)
uInfo
(
"lossy compression float is opened. "
);
if
(
lossyDouble
)
...
...
src/util/src/tconfig.c
浏览文件 @
bea199ce
...
...
@@ -484,6 +484,9 @@ void taosPrintGlobalCfg() {
case
TAOS_CFG_VTYPE_FLOAT
:
uInfo
(
" %s:%s%f%s"
,
cfg
->
option
,
blank
,
*
((
float
*
)
cfg
->
ptr
),
tsGlobalUnit
[
cfg
->
unitType
]);
break
;
case
TAOS_CFG_VTYPE_DOUBLE
:
uInfo
(
" %s:%s%f%s"
,
cfg
->
option
,
blank
,
*
((
double
*
)
cfg
->
ptr
),
tsGlobalUnit
[
cfg
->
unitType
]);
break
;
case
TAOS_CFG_VTYPE_STRING
:
case
TAOS_CFG_VTYPE_IPSTR
:
case
TAOS_CFG_VTYPE_DIRECTORY
:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录