Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
yiicenne
TDengine
提交
12aa99da
TDengine
项目概览
yiicenne
/
TDengine
与 Fork 源项目一致
Fork自
taosdata / TDengine
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
TDengine
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
12aa99da
编写于
12月 24, 2020
作者:
H
huili
提交者:
GitHub
12月 24, 2020
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #4676 from taosdata/test/jenkins
[TD-2491][TD-2492]modify Jenkinsfile
上级
fc0b642a
8fd26a42
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
60 addition
and
49 deletion
+60
-49
tests/Jenkinsfile
tests/Jenkinsfile
+41
-41
tests/pytest/concurrent_inquiry.py
tests/pytest/concurrent_inquiry.py
+6
-2
tests/pytest/handle_crash_gen_val_log.sh
tests/pytest/handle_crash_gen_val_log.sh
+4
-3
tests/test-all.sh
tests/test-all.sh
+9
-3
未找到文件。
tests/Jenkinsfile
浏览文件 @
12aa99da
...
...
@@ -50,12 +50,7 @@ pipeline {
agent
{
label
'master'
}
steps
{
pre_test
()
catchError
(
buildResult:
'SUCCESS'
,
stageResult:
'FAILURE'
)
{
sh
'''
cd ${WKC}/tests/pytest
python3 concurrent_inquiry.py -c 1
'''
}
sh
'''
cd ${WKC}/tests
./test-all.sh b1
...
...
@@ -82,53 +77,26 @@ pipeline {
./handle_crash_gen_val_log.sh
'''
}
sh
'''
cd ${WKC}/tests
./test-all.sh b2
date
'''
}
}
stage
(
'test_valgrind'
)
{
agent
{
label
"186"
}
steps
{
pre_test
()
sh
'''
cd ${WKC}/tests/pytest
./valgrind-test.sh 2>&1 > mem-error-out.log
./handle_val_log.sh
date
cd ${WKC}/tests
./test-all.sh b3
date'''
}
}
stage
(
'connector'
){
agent
{
label
"release"
}
steps
{
sh
'''
cd ${WORKSPACE}
git checkout develop
systemctl start taosd
sleep 10
'''
catchError
(
buildResult:
'SUCCESS'
,
stageResult:
'FAILURE'
)
{
sh
'''
cd ${W
ORKSPACE
}/tests/gotest
cd ${W
KC
}/tests/gotest
bash batchtest.sh
'''
}
catchError
(
buildResult:
'SUCCESS'
,
stageResult:
'FAILURE'
)
{
sh
'''
cd ${W
ORKSPACE
}/tests/examples/python/PYTHONConnectorChecker
cd ${W
KC
}/tests/examples/python/PYTHONConnectorChecker
python3 PythonChecker.py
'''
}
catchError
(
buildResult:
'SUCCESS'
,
stageResult:
'FAILURE'
)
{
sh
'''
cd ${W
ORKSPACE
}/tests/examples/JDBC/JDBCDemo/
mvn clean package assembly:single >/dev/null
cd ${W
KC
}/tests/examples/JDBC/JDBCDemo/
mvn clean package assembly:single
-DskipTests
>/dev/null
java -jar target/jdbcChecker-SNAPSHOT-jar-with-dependencies.jar -host 127.0.0.1
'''
}
...
...
@@ -138,9 +106,41 @@ pipeline {
dotnet run
'''
}
sh
'''
systemctl stop taosd
cd ${WKC}/tests
./test-all.sh b2
date
'''
}
}
stage
(
'test_valgrind'
)
{
agent
{
label
"186"
}
steps
{
pre_test
()
catchError
(
buildResult:
'SUCCESS'
,
stageResult:
'FAILURE'
)
{
sh
'''
cd ${WKC}/tests/pytest
nohup taosd >/dev/null &
sleep 10
python3 concurrent_inquiry.py -c 1
'''
}
sh
'''
cd ${WKC}/tests/pytest
./valgrind-test.sh 2>&1 > mem-error-out.log
./handle_val_log.sh
}
}
date
cd ${WKC}/tests
./test-all.sh b3
date'''
}
}
stage
(
'arm64_build'
){
agent
{
label
'arm64'
}
steps
{
...
...
tests/pytest/concurrent_inquiry.py
浏览文件 @
12aa99da
...
...
@@ -388,7 +388,9 @@ class ConcurrentInquiry:
print
(
"Failure thread%d, sql: %s
\n
exception: %s"
%
(
threadID
,
str
(
sql
),
str
(
e
)))
#exit(-1)
err_uec
=
'Unable to establish connection'
if
err_uec
in
str
(
e
)
and
loop
>
0
:
exit
(
-
1
)
loop
-=
1
if
loop
==
0
:
break
...
...
@@ -415,7 +417,9 @@ class ConcurrentInquiry:
print
(
"Failure thread%d, sql: %s
\n
exception: %s"
%
(
threadID
,
str
(
sql
),
str
(
e
)))
#exit(-1)
err_uec
=
'Unable to establish connection'
if
err_uec
in
str
(
e
)
and
loop
>
0
:
exit
(
-
1
)
loop
-=
1
if
loop
==
0
:
break
...
...
tests/pytest/handle_crash_gen_val_log.sh
浏览文件 @
12aa99da
...
...
@@ -5,9 +5,10 @@ GREEN='\033[1;32m'
GREEN_DARK
=
'\033[0;32m'
GREEN_UNDERLINE
=
'\033[4;32m'
NC
=
'\033[0m'
nohup
/var/lib/jenkins/workspace/TDinternal/debug/build/bin/taosd
-c
/var/lib/jenkins/workspace/TDinternal/community/sim/dnode1/cfg
>
/dev/null &
#nohup /var/lib/jenkins/workspace/TDinternal/debug/build/bin/taosd -c /var/lib/jenkins/workspace/TDinternal/community/sim/dnode1/cfg >/dev/null &
nohup
/root/TDinternal/debug/build/bin/taosd
-c
/root/TDinternal/community/sim/dnode1/cfg
>
/dev/null &
./crash_gen.sh
--valgrind
-p
-t
10
-s
250
-b
4
pidof taosd|xargs
kill
pidof taosd|xargs
kill
-9
grep
'start to execute\|ERROR SUMMARY'
valgrind.err|grep
-v
'grep'
|uniq|tee crash_gen_mem_err.log
for
memError
in
`
grep
'ERROR SUMMARY'
crash_gen_mem_err.log |
awk
'{print $4}'
`
...
...
@@ -31,4 +32,4 @@ if [ -n "$defiMemError" ]; then
exit
8
fi
fi
done
\ No newline at end of file
done
tests/test-all.sh
浏览文件 @
12aa99da
...
...
@@ -31,11 +31,17 @@ function runSimCaseOneByOnefq {
case
=
`
echo
$line
|
grep
sim
$
|awk
'{print $NF}'
`
start_time
=
`
date
+%s
`
./test.sh
-f
$case
>
/dev/null 2>&1
&&
\
IN_TDINTERNAL
=
"community"
if
[[
"
$tests_dir
"
==
*
"
$IN_TDINTERNAL
"
*
]]
;
then
./test.sh
-f
$case
>
/dev/null 2>&1
&&
\
echo
-e
"
${
GREEN
}
$case
success
${
NC
}
"
|
tee
-a
out.log
||
\
(
grep
'script.*success.*m$'
../../../sim/tsim/log/taoslog0.0
&&
echo
-e
"
${
GREEN
}
$case
success
${
NC
}
"
|
tee
-a
out.log
)
||
echo
-e
"
${
RED
}
$case
failed
${
NC
}
"
|
tee
-a
out.log
else
./test.sh
-f
$case
>
/dev/null 2>&1
&&
\
echo
-e
"
${
GREEN
}
$case
success
${
NC
}
"
|
tee
-a
out.log
||
\
(
grep
'script.*success.*m$'
../../sim/tsim/log/taoslog0.0
&&
echo
-e
"
${
GREEN
}
$case
success
${
NC
}
"
|
tee
-a
out.log
)
||
echo
-e
"
${
RED
}
$case
failed
${
NC
}
"
|
tee
-a
out.log
fi
out_log
=
`
tail
-1
out.log
`
if
[[
$out_log
=
~
'failed'
]]
;
then
exit
8
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录