Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
c5874bcf
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
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看板
未验证
提交
c5874bcf
编写于
1月 22, 2022
作者:
S
Shengliang Guan
提交者:
GitHub
1月 22, 2022
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #9971 from taosdata/feature/warning
Feature/warning
上级
963ef70e
1c00fd6b
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
27 addition
and
27 deletion
+27
-27
source/dnode/vnode/src/vnd/vnodeWrite.c
source/dnode/vnode/src/vnd/vnodeWrite.c
+2
-1
source/libs/scheduler/src/scheduler.c
source/libs/scheduler/src/scheduler.c
+1
-1
tests/script/sh/deploy.sh
tests/script/sh/deploy.sh
+2
-0
tests/test/c/create_table.c
tests/test/c/create_table.c
+20
-24
tests/tsim/src/simSystem.c
tests/tsim/src/simSystem.c
+2
-1
未找到文件。
source/dnode/vnode/src/vnd/vnodeWrite.c
浏览文件 @
c5874bcf
...
...
@@ -96,7 +96,7 @@ int vnodeApplyWMsg(SVnode *pVnode, SRpcMsg *pMsg, SRpcMsg **pRsp) {
}
}
v
Debug
(
"vgId:%d process create %"
PRIzu
" tables"
,
pVnode
->
vgId
,
taosArrayGetSize
(
vCreateTbBatchReq
.
pArray
));
v
Trace
(
"vgId:%d process create %"
PRIzu
" tables"
,
pVnode
->
vgId
,
taosArrayGetSize
(
vCreateTbBatchReq
.
pArray
));
taosArrayDestroy
(
vCreateTbBatchReq
.
pArray
);
break
;
...
...
@@ -131,6 +131,7 @@ int vnodeApplyWMsg(SVnode *pVnode, SRpcMsg *pMsg, SRpcMsg **pRsp) {
// TODO: handle error
}
}
return
0
;
}
...
...
source/libs/scheduler/src/scheduler.c
浏览文件 @
c5874bcf
...
...
@@ -734,7 +734,7 @@ int32_t schProcessOnTaskSuccess(SSchJob *pJob, SSchTask *pTask) {
SCH_UNLOCK
(
SCH_WRITE
,
&
pTask
->
level
->
lock
);
if
(
taskDone
<
pTask
->
level
->
taskNum
)
{
SCH_TASK_
E
LOG
(
"wait all tasks, done:%d, all:%d"
,
taskDone
,
pTask
->
level
->
taskNum
);
SCH_TASK_
D
LOG
(
"wait all tasks, done:%d, all:%d"
,
taskDone
,
pTask
->
level
->
taskNum
);
return
TSDB_CODE_SUCCESS
;
}
else
if
(
taskDone
>
pTask
->
level
->
taskNum
)
{
...
...
tests/script/sh/deploy.sh
浏览文件 @
c5874bcf
...
...
@@ -115,6 +115,8 @@ elif [ $NODE -eq 8 ]; then
NODE
=
7800
fi
HOSTNAME
=
localhost
echo
" "
>>
$TAOS_CFG
echo
"firstEp
${
HOSTNAME
}
:7100"
>>
$TAOS_CFG
echo
"secondEp
${
HOSTNAME
}
:7200"
>>
$TAOS_CFG
...
...
tests/test/c/create_table.c
浏览文件 @
c5874bcf
...
...
@@ -35,8 +35,7 @@ int32_t numOfVgroups = 2;
int32_t
showTablesFlag
=
0
;
int32_t
queryFlag
=
0
;
int64_t
startTimestamp
=
1640966400000
;
// 2020-01-01 00:00:00.000
int64_t
startTimestamp
=
1640966400000
;
// 2020-01-01 00:00:00.000
typedef
struct
{
int64_t
tableBeginIndex
;
...
...
@@ -89,7 +88,7 @@ void createDbAndStb() {
pRes
=
taos_query
(
con
,
qstr
);
code
=
taos_errno
(
pRes
);
if
(
code
!=
0
)
{
pError
(
"failed to
use db
, code:%d reason:%s"
,
taos_errno
(
pRes
),
taos_errstr
(
pRes
));
pError
(
"failed to
create stable
, code:%d reason:%s"
,
taos_errno
(
pRes
),
taos_errstr
(
pRes
));
exit
(
0
);
}
taos_free_result
(
pRes
);
...
...
@@ -182,18 +181,14 @@ void *threadFunc(void *param) {
exit
(
1
);
}
pPrint
(
"====before thread:%d, table range: %"
PRId64
" - %"
PRId64
"
\n
"
,
pInfo
->
threadIndex
,
pInfo
->
tableBeginIndex
,
pInfo
->
tableEndIndex
);
pPrint
(
"====before thread:%d, table range: %"
PRId64
" - %"
PRId64
"
\n
"
,
pInfo
->
threadIndex
,
pInfo
->
tableBeginIndex
,
pInfo
->
tableEndIndex
);
pInfo
->
tableBeginIndex
+=
startOffset
;
pInfo
->
tableEndIndex
+=
startOffset
;
pInfo
->
tableEndIndex
+=
startOffset
;
pPrint
(
"====after thread:%d, table range: %"
PRId64
" - %"
PRId64
"
\n
"
,
pInfo
->
threadIndex
,
pInfo
->
tableBeginIndex
,
pInfo
->
tableEndIndex
);
pPrint
(
"====after thread:%d, table range: %"
PRId64
" - %"
PRId64
"
\n
"
,
pInfo
->
threadIndex
,
pInfo
->
tableBeginIndex
,
pInfo
->
tableEndIndex
);
sprintf
(
qstr
,
"use %s"
,
pInfo
->
dbName
);
TAOS_RES
*
pRes
=
taos_query
(
con
,
qstr
);
...
...
@@ -221,7 +216,7 @@ void *threadFunc(void *param) {
int64_t
startTs
=
taosGetTimestampUs
();
TAOS_RES
*
pRes
=
taos_query
(
con
,
qstr
);
code
=
taos_errno
(
pRes
);
if
(
(
code
!=
0
)
&&
(
code
!=
TSDB_CODE_RPC_AUTH_REQUIRED
)
)
{
if
(
code
!=
0
)
{
pError
(
"failed to create table reason:%s, sql: %s"
,
tstrerror
(
code
),
qstr
);
}
taos_free_result
(
pRes
);
...
...
@@ -251,20 +246,20 @@ void *threadFunc(void *param) {
// batch = MIN(batch, batchNum);
int32_t
len
=
sprintf
(
qstr
,
"insert into "
);
for
(
int32_t
i
=
0
;
i
<
batchNumOfTbl
;)
{
int64_t
ts
=
startTimestamp
;
int64_t
ts
=
startTimestamp
;
len
+=
sprintf
(
qstr
+
len
,
"%s_t%"
PRId64
" values "
,
stbName
,
t
);
for
(
int32_t
j
=
0
;
j
<
batchNumOfRow
;
j
++
)
{
len
+=
sprintf
(
qstr
+
len
,
"(%"
PRId64
", 6666) "
,
ts
++
);
len
+=
sprintf
(
qstr
+
len
,
"(%"
PRId64
", 6666) "
,
ts
++
);
}
t
++
;
i
++
;
if
(
t
>
pInfo
->
tableEndIndex
)
{
break
;
}
}
}
int64_t
startTs
=
taosGetTimestampUs
();
TAOS_RES
*
pRes
=
taos_query
(
con
,
qstr
);
...
...
@@ -360,7 +355,7 @@ void parseArgument(int32_t argc, char *argv[]) {
}
else
if
(
strcmp
(
argv
[
i
],
"-q"
)
==
0
)
{
queryFlag
=
atoi
(
argv
[
++
i
]);
}
else
{
pPrint
(
"%s unknow para: %s %s"
,
GREEN
,
argv
[
++
i
],
NC
);
pPrint
(
"%s unknow para: %s %s"
,
GREEN
,
argv
[
++
i
],
NC
);
}
}
...
...
@@ -390,15 +385,16 @@ int32_t main(int32_t argc, char *argv[]) {
}
if
(
queryFlag
)
{
//selectRowsFromTable();
//
selectRowsFromTable();
return
0
;
}
if
(
createTable
)
{
createDbAndStb
();
}
pPrint
(
"%d threads are spawned to create %"
PRId64
" tables, offset is %"
PRId64
" "
,
numOfThreads
,
numOfTables
,
startOffset
);
pPrint
(
"%d threads are spawned to create %"
PRId64
" tables, offset is %"
PRId64
" "
,
numOfThreads
,
numOfTables
,
startOffset
);
pthread_attr_t
thattr
;
pthread_attr_init
(
&
thattr
);
...
...
@@ -456,8 +452,8 @@ int32_t main(int32_t argc, char *argv[]) {
if
(
createTable
)
{
pPrint
(
"%s total %"
PRId64
" tables, %.1f tables/second, threads:%d, maxDelay: %"
PRId64
"us, minDelay: %"
PRId64
"us %s"
,
GREEN
,
numOfTables
,
createTableSpeed
,
numOfThreads
,
maxDelay
,
minDelay
,
NC
);
"us %s"
,
GREEN
,
numOfTables
,
createTableSpeed
,
numOfThreads
,
maxDelay
,
minDelay
,
NC
);
}
if
(
insertData
)
{
...
...
tests/tsim/src/simSystem.c
浏览文件 @
c5874bcf
...
...
@@ -42,7 +42,8 @@ char *simParseArbitratorName(char *varName) {
char
*
simParseHostName
(
char
*
varName
)
{
static
char
hostName
[
140
];
sprintf
(
hostName
,
"%s"
,
simHostName
);
//sprintf(hostName, "%s", simHostName);
sprintf
(
hostName
,
"%s"
,
"localhost"
);
return
hostName
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录