Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
abe9b756
T
TDengine
项目概览
taosdata
/
TDengine
大约 2 年 前同步成功
通知
1192
Star
22018
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看板
提交
abe9b756
编写于
5月 19, 2021
作者:
haoranc
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of github.com:taosdata/TDengine into test/chr
上级
0f96df1f
48f49de9
变更
4
展开全部
隐藏空白更改
内联
并排
Showing
4 changed file
with
285 addition
and
122 deletion
+285
-122
src/kit/taosdemo/subscribe.json
src/kit/taosdemo/subscribe.json
+30
-10
src/kit/taosdemo/taosdemo.c
src/kit/taosdemo/taosdemo.c
+239
-99
src/vnode/src/vnodeWrite.c
src/vnode/src/vnodeWrite.c
+5
-2
tests/pytest/tools/taosdemoTestWithJson.py
tests/pytest/tools/taosdemoTestWithJson.py
+11
-11
未找到文件。
src/kit/taosdemo/subscribe.json
浏览文件 @
abe9b756
{
"filetype"
:
"subscribe"
,
"filetype"
:
"subscribe"
,
"cfgdir"
:
"/etc/taos"
,
"host"
:
"127.0.0.1"
,
"port"
:
6030
,
"user"
:
"root"
,
"password"
:
"taosdata"
,
"databases"
:
"dbx"
,
"specified_table_query"
:
{
"concurrent"
:
1
,
"mode"
:
"sync"
,
"interval"
:
5000
,
"restart"
:
"yes"
,
"keepProgress"
:
"yes"
,
"sqls"
:
[{
"sql"
:
"select avg(col1) from stb01 where col1 > 1;"
,
"result"
:
"./subscribe_res0.txt"
}]
},
"super_table_query"
:
{
"stblname"
:
"stb"
,
"threads"
:
1
,
"mode"
:
"sync"
,
"interval"
:
10000
,
"restart"
:
"yes"
,
"keepProgress"
:
"yes"
,
"sqls"
:
[{
"sql"
:
"select col1 from xxxx where col1 > 10;"
,
"result"
:
"./subscribe_res1.txt"
}]
}
"databases"
:
"test"
,
"specified_table_query"
:
{
"concurrent"
:
1
,
"mode"
:
"sync"
,
"interval"
:
1000
,
"restart"
:
"yes"
,
"keepProgress"
:
"yes"
,
"resubAfterConsume"
:
10
,
"sqls"
:
[
{
"sql"
:
"select avg(col1) from meters where col1 > 1;"
,
"result"
:
"./subscribe_res0.txt"
}
]
},
"super_table_query"
:
{
"stblname"
:
"meters"
,
"threads"
:
1
,
"mode"
:
"sync"
,
"interval"
:
1000
,
"restart"
:
"yes"
,
"keepProgress"
:
"yes"
,
"sqls"
:
[
{
"sql"
:
"select col1 from xxxx where col1 > 10;"
,
"result"
:
"./subscribe_res1.txt"
}
]
}
}
src/kit/taosdemo/taosdemo.c
浏览文件 @
abe9b756
此差异已折叠。
点击以展开。
src/vnode/src/vnodeWrite.c
浏览文件 @
abe9b756
...
...
@@ -340,8 +340,11 @@ static void vnodeFlowCtrlMsgToWQueue(void *param, void *tmrId) {
if
(
pWrite
->
processedCount
>=
100
)
{
vError
(
"vgId:%d, msg:%p, failed to process since %s, retry:%d"
,
pVnode
->
vgId
,
pWrite
,
tstrerror
(
code
),
pWrite
->
processedCount
);
pWrite
->
processedCount
=
1
;
dnodeSendRpcVWriteRsp
(
pWrite
->
pVnode
,
pWrite
,
code
);
void
*
handle
=
pWrite
->
rpcMsg
.
handle
;
taosFreeQitem
(
pWrite
);
vnodeRelease
(
pVnode
);
SRpcMsg
rpcRsp
=
{.
handle
=
handle
,
.
code
=
code
};
rpcSendResponse
(
&
rpcRsp
);
}
else
{
code
=
vnodePerformFlowCtrl
(
pWrite
);
if
(
code
==
0
)
{
...
...
tests/pytest/tools/taosdemoTestWithJson.py
浏览文件 @
abe9b756
...
...
@@ -23,32 +23,32 @@ class TDTestCase:
def
init
(
self
,
conn
,
logSql
):
tdLog
.
debug
(
"start to execute %s"
%
__file__
)
tdSql
.
init
(
conn
.
cursor
(),
logSql
)
def
getBuildPath
(
self
):
selfPath
=
os
.
path
.
dirname
(
os
.
path
.
realpath
(
__file__
))
if
(
"community"
in
selfPath
)
:
projPath
=
selfPath
[:
selfPath
.
find
(
"community"
)]
if
"community"
in
selfPath
:
projPath
=
selfPath
[:
selfPath
.
find
(
"community"
)]
else
:
projPath
=
selfPath
[:
selfPath
.
find
(
"tests"
)]
projPath
=
selfPath
[:
selfPath
.
find
(
"tests"
)]
for
root
,
dirs
,
files
in
os
.
walk
(
projPath
):
if
(
"taosd"
in
files
)
:
if
"taosd"
in
files
:
rootRealPath
=
os
.
path
.
dirname
(
os
.
path
.
realpath
(
root
))
if
(
"packaging"
not
in
rootRealPath
)
:
buildPath
=
root
[:
len
(
root
)
-
len
(
"/build/bin"
)]
if
"packaging"
not
in
rootRealPath
:
buildPath
=
root
[:
len
(
root
)
-
len
(
"/build/bin"
)]
break
return
buildPath
def
run
(
self
):
tdSql
.
prepare
()
buildPath
=
self
.
getBuildPath
()
if
(
buildPath
==
""
)
:
if
buildPath
==
""
:
tdLog
.
exit
(
"taosd not found!"
)
else
:
tdLog
.
info
(
"taosd found in %s"
%
buildPath
)
binPath
=
buildPath
+
"/build/bin/"
os
.
system
(
"
yes | %staosdemo -f tools/insert.json
"
%
binPath
)
binPath
=
buildPath
+
"/build/bin/"
os
.
system
(
"
%staosdemo -f tools/insert.json -y
"
%
binPath
)
tdSql
.
execute
(
"use db01"
)
tdSql
.
query
(
"select count(*) from stb01"
)
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录