Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
05d2260d
TDengine
项目概览
taosdata
/
TDengine
大约 2 年 前同步成功
通知
1192
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看板
提交
05d2260d
编写于
10月 27, 2020
作者:
H
Haojun Liao
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[td-225] add tcp transfer threshold
上级
74ddf041
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
10 addition
and
1 deletion
+10
-1
src/inc/tglobalcfg.h
src/inc/tglobalcfg.h
+2
-0
src/rpc/src/tudp.c
src/rpc/src/tudp.c
+2
-1
src/util/src/tglobalcfg.c
src/util/src/tglobalcfg.c
+6
-0
未找到文件。
src/inc/tglobalcfg.h
浏览文件 @
05d2260d
...
@@ -122,6 +122,8 @@ extern int tsBalancePolicy;
...
@@ -122,6 +122,8 @@ extern int tsBalancePolicy;
extern
int
tsOfflineThreshold
;
extern
int
tsOfflineThreshold
;
extern
int
tsMgmtEqualVnodeNum
;
extern
int
tsMgmtEqualVnodeNum
;
extern
int
tsTCPTransferThreshold
;
extern
int
tsEnableHttpModule
;
extern
int
tsEnableHttpModule
;
extern
int
tsEnableMonitorModule
;
extern
int
tsEnableMonitorModule
;
extern
int
tsRestRowLimit
;
extern
int
tsRestRowLimit
;
...
...
src/rpc/src/tudp.c
浏览文件 @
05d2260d
...
@@ -756,7 +756,8 @@ int taosSendUdpData(uint32_t ip, uint16_t port, char *data, int dataLen, void *c
...
@@ -756,7 +756,8 @@ int taosSendUdpData(uint32_t ip, uint16_t port, char *data, int dataLen, void *c
if
(
pConn
==
NULL
||
pConn
->
signature
!=
pConn
)
return
-
1
;
if
(
pConn
==
NULL
||
pConn
->
signature
!=
pConn
)
return
-
1
;
if
(
dataLen
>=
RPC_MAX_UDP_SIZE
)
return
taosSendPacketViaTcp
(
ip
,
port
,
data
,
dataLen
,
chandle
);
assert
(
tsTCPTransferThreshold
<=
RPC_MAX_UDP_SIZE
&&
tsTCPTransferThreshold
>
0
);
if
(
dataLen
>=
tsTCPTransferThreshold
)
return
taosSendPacketViaTcp
(
ip
,
port
,
data
,
dataLen
,
chandle
);
if
(
pConn
->
hash
==
NULL
)
{
if
(
pConn
->
hash
==
NULL
)
{
struct
sockaddr_in
destAdd
;
struct
sockaddr_in
destAdd
;
...
...
src/util/src/tglobalcfg.c
浏览文件 @
05d2260d
...
@@ -130,6 +130,8 @@ int tsBalancePolicy = 0; // 1-use sys.montor
...
@@ -130,6 +130,8 @@ int tsBalancePolicy = 0; // 1-use sys.montor
int
tsOfflineThreshold
=
864000
;
// seconds 10days
int
tsOfflineThreshold
=
864000
;
// seconds 10days
int
tsMgmtEqualVnodeNum
=
4
;
int
tsMgmtEqualVnodeNum
=
4
;
int
tsTCPTransferThreshold
=
65480
;
// RPC_MAX_UDP_SIZE
int
tsEnableHttpModule
=
1
;
int
tsEnableHttpModule
=
1
;
int
tsEnableMonitorModule
=
1
;
int
tsEnableMonitorModule
=
1
;
int
tsRestRowLimit
=
10240
;
int
tsRestRowLimit
=
10240
;
...
@@ -710,6 +712,10 @@ static void doInitGlobalConfig() {
...
@@ -710,6 +712,10 @@ static void doInitGlobalConfig() {
TSDB_CFG_CTYPE_B_CONFIG
|
TSDB_CFG_CTYPE_B_CLIENT
,
TSDB_CFG_CTYPE_B_CONFIG
|
TSDB_CFG_CTYPE_B_CLIENT
,
0
,
0
,
tListLen
(
tsCharset
),
TSDB_CFG_UTYPE_NONE
);
0
,
0
,
tListLen
(
tsCharset
),
TSDB_CFG_UTYPE_NONE
);
tsInitConfigOption
(
cfg
++
,
"tcptransferThreshold"
,
&
tsTCPTransferThreshold
,
TSDB_CFG_VTYPE_INT
,
TSDB_CFG_CTYPE_B_CONFIG
|
TSDB_CFG_CTYPE_B_SHOW
,
500
,
65480
,
0
,
TSDB_CFG_UTYPE_BYTE
);
// connect configs
// connect configs
tsInitConfigOption
(
cfg
++
,
"maxShellConns"
,
&
tsMaxShellConns
,
TSDB_CFG_VTYPE_INT
,
tsInitConfigOption
(
cfg
++
,
"maxShellConns"
,
&
tsMaxShellConns
,
TSDB_CFG_VTYPE_INT
,
TSDB_CFG_CTYPE_B_CONFIG
|
TSDB_CFG_CTYPE_B_SHOW
,
TSDB_CFG_CTYPE_B_CONFIG
|
TSDB_CFG_CTYPE_B_SHOW
,
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录