Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
957ed637
T
TDengine
项目概览
taosdata
/
TDengine
1 年多 前同步成功
通知
1185
Star
22016
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看板
提交
957ed637
编写于
2月 15, 2023
作者:
D
dapan1121
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix: rsp type mismatch after link broken is processed
上级
e010d358
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
9 addition
and
5 deletion
+9
-5
source/libs/scheduler/inc/schInt.h
source/libs/scheduler/inc/schInt.h
+1
-0
source/libs/scheduler/src/schRemote.c
source/libs/scheduler/src/schRemote.c
+4
-4
source/libs/scheduler/src/schTask.c
source/libs/scheduler/src/schTask.c
+4
-1
未找到文件。
source/libs/scheduler/inc/schInt.h
浏览文件 @
957ed637
...
@@ -230,6 +230,7 @@ typedef struct SSchTask {
...
@@ -230,6 +230,7 @@ typedef struct SSchTask {
SSchRedirectCtx
redirectCtx
;
// task redirect context
SSchRedirectCtx
redirectCtx
;
// task redirect context
bool
waitRetry
;
// wait for retry
bool
waitRetry
;
// wait for retry
int32_t
execId
;
// task current execute index
int32_t
execId
;
// task current execute index
int32_t
failedExecId
;
// last failed task execute index
SSchLevel
*
level
;
// level
SSchLevel
*
level
;
// level
SRWLatch
planLock
;
// task update plan lock
SRWLatch
planLock
;
// task update plan lock
SSubplan
*
plan
;
// subplan
SSubplan
*
plan
;
// subplan
...
...
source/libs/scheduler/src/schRemote.c
浏览文件 @
957ed637
...
@@ -34,12 +34,12 @@ int32_t schValidateRspMsgType(SSchJob *pJob, SSchTask *pTask, int32_t msgType) {
...
@@ -34,12 +34,12 @@ int32_t schValidateRspMsgType(SSchJob *pJob, SSchTask *pTask, int32_t msgType) {
if
(
lastMsgType
!=
reqMsgType
)
{
if
(
lastMsgType
!=
reqMsgType
)
{
SCH_TASK_ELOG
(
"rsp msg type mis-match, last sent msgType:%s, rspType:%s"
,
TMSG_INFO
(
lastMsgType
),
SCH_TASK_ELOG
(
"rsp msg type mis-match, last sent msgType:%s, rspType:%s"
,
TMSG_INFO
(
lastMsgType
),
TMSG_INFO
(
msgType
));
TMSG_INFO
(
msgType
));
SCH_ERR_RET
(
TSDB_CODE_
SCH_STATUS
_ERROR
);
SCH_ERR_RET
(
TSDB_CODE_
QW_MSG
_ERROR
);
}
}
if
(
taskStatus
!=
JOB_TASK_STATUS_PART_SUCC
)
{
if
(
taskStatus
!=
JOB_TASK_STATUS_PART_SUCC
)
{
SCH_TASK_ELOG
(
"rsp msg conflicted with task status, status:%s, rspType:%s"
,
jobTaskStatusStr
(
taskStatus
),
SCH_TASK_ELOG
(
"rsp msg conflicted with task status, status:%s, rspType:%s"
,
jobTaskStatusStr
(
taskStatus
),
TMSG_INFO
(
msgType
));
TMSG_INFO
(
msgType
));
SCH_ERR_RET
(
TSDB_CODE_
SCH_STATUS
_ERROR
);
SCH_ERR_RET
(
TSDB_CODE_
QW_MSG
_ERROR
);
}
}
return
TSDB_CODE_SUCCESS
;
return
TSDB_CODE_SUCCESS
;
...
@@ -60,13 +60,13 @@ int32_t schValidateRspMsgType(SSchJob *pJob, SSchTask *pTask, int32_t msgType) {
...
@@ -60,13 +60,13 @@ int32_t schValidateRspMsgType(SSchJob *pJob, SSchTask *pTask, int32_t msgType) {
if
(
lastMsgType
!=
reqMsgType
)
{
if
(
lastMsgType
!=
reqMsgType
)
{
SCH_TASK_ELOG
(
"rsp msg type mis-match, last sent msgType:%s, rspType:%s"
,
TMSG_INFO
(
lastMsgType
),
SCH_TASK_ELOG
(
"rsp msg type mis-match, last sent msgType:%s, rspType:%s"
,
TMSG_INFO
(
lastMsgType
),
TMSG_INFO
(
msgType
));
TMSG_INFO
(
msgType
));
SCH_ERR_RET
(
TSDB_CODE_
SCH_STATUS
_ERROR
);
SCH_ERR_RET
(
TSDB_CODE_
QW_MSG
_ERROR
);
}
}
if
(
taskStatus
!=
JOB_TASK_STATUS_EXEC
)
{
if
(
taskStatus
!=
JOB_TASK_STATUS_EXEC
)
{
SCH_TASK_ELOG
(
"rsp msg conflicted with task status, status:%s, rspType:%s"
,
jobTaskStatusStr
(
taskStatus
),
SCH_TASK_ELOG
(
"rsp msg conflicted with task status, status:%s, rspType:%s"
,
jobTaskStatusStr
(
taskStatus
),
TMSG_INFO
(
msgType
));
TMSG_INFO
(
msgType
));
SCH_ERR_RET
(
TSDB_CODE_
SCH_STATUS
_ERROR
);
SCH_ERR_RET
(
TSDB_CODE_
QW_MSG
_ERROR
);
}
}
return
TSDB_CODE_SUCCESS
;
return
TSDB_CODE_SUCCESS
;
...
...
source/libs/scheduler/src/schTask.c
浏览文件 @
957ed637
...
@@ -64,6 +64,7 @@ int32_t schInitTask(SSchJob *pJob, SSchTask *pTask, SSubplan *pPlan, SSchLevel *
...
@@ -64,6 +64,7 @@ int32_t schInitTask(SSchJob *pJob, SSchTask *pTask, SSubplan *pPlan, SSchLevel *
pTask
->
plan
=
pPlan
;
pTask
->
plan
=
pPlan
;
pTask
->
level
=
pLevel
;
pTask
->
level
=
pLevel
;
pTask
->
execId
=
-
1
;
pTask
->
execId
=
-
1
;
pTask
->
failedExecId
=
-
2
;
pTask
->
timeoutUsec
=
SCH_DEFAULT_TASK_TIMEOUT_USEC
;
pTask
->
timeoutUsec
=
SCH_DEFAULT_TASK_TIMEOUT_USEC
;
pTask
->
taskId
=
schGenTaskId
();
pTask
->
taskId
=
schGenTaskId
();
...
@@ -166,7 +167,7 @@ int32_t schUpdateTaskHandle(SSchJob *pJob, SSchTask *pTask, bool dropExecNode, v
...
@@ -166,7 +167,7 @@ int32_t schUpdateTaskHandle(SSchJob *pJob, SSchTask *pTask, bool dropExecNode, v
schUpdateTaskExecNode
(
pJob
,
pTask
,
handle
,
execId
);
schUpdateTaskExecNode
(
pJob
,
pTask
,
handle
,
execId
);
if
((
execId
!=
pTask
->
execId
)
||
pTask
->
waitRetry
)
{
// ignore it
if
((
execId
!=
pTask
->
execId
||
execId
<=
pTask
->
failedExecId
)
||
pTask
->
waitRetry
)
{
// ignore it
SCH_TASK_DLOG
(
"handle not updated since execId %d is already not current execId %d, waitRetry %d"
,
execId
,
SCH_TASK_DLOG
(
"handle not updated since execId %d is already not current execId %d, waitRetry %d"
,
execId
,
pTask
->
execId
,
pTask
->
waitRetry
);
pTask
->
execId
,
pTask
->
waitRetry
);
SCH_ERR_RET
(
TSDB_CODE_SCH_IGNORE_ERROR
);
SCH_ERR_RET
(
TSDB_CODE_SCH_IGNORE_ERROR
);
...
@@ -182,6 +183,8 @@ int32_t schProcessOnTaskFailure(SSchJob *pJob, SSchTask *pTask, int32_t errCode)
...
@@ -182,6 +183,8 @@ int32_t schProcessOnTaskFailure(SSchJob *pJob, SSchTask *pTask, int32_t errCode)
return
TSDB_CODE_SCH_IGNORE_ERROR
;
return
TSDB_CODE_SCH_IGNORE_ERROR
;
}
}
pTask
->
failedExecId
=
pTask
->
execId
;
int8_t
jobStatus
=
0
;
int8_t
jobStatus
=
0
;
if
(
schJobNeedToStop
(
pJob
,
&
jobStatus
))
{
if
(
schJobNeedToStop
(
pJob
,
&
jobStatus
))
{
SCH_TASK_DLOG
(
"no more task failure processing cause of job status %s"
,
jobTaskStatusStr
(
jobStatus
));
SCH_TASK_DLOG
(
"no more task failure processing cause of job status %s"
,
jobTaskStatusStr
(
jobStatus
));
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录