Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
taosdata
TDengine
提交
4393375e
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看板
提交
4393375e
编写于
8月 10, 2023
作者:
H
Haojun Liao
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix(stream): set correct task id.
上级
0757e88c
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
16 addition
and
10 deletion
+16
-10
source/dnode/mnode/impl/src/mndScheduler.c
source/dnode/mnode/impl/src/mndScheduler.c
+4
-3
source/dnode/snode/src/snode.c
source/dnode/snode/src/snode.c
+7
-4
source/dnode/vnode/src/tq/tq.c
source/dnode/vnode/src/tq/tq.c
+3
-2
source/libs/stream/src/streamRecover.c
source/libs/stream/src/streamRecover.c
+2
-1
未找到文件。
source/dnode/mnode/impl/src/mndScheduler.c
浏览文件 @
4393375e
...
...
@@ -232,7 +232,8 @@ int32_t mndAddShuffleSinkTasksToStream(SMnode* pMnode, SArray* pTaskList, SStrea
int32_t
mndAddSinkTaskToStream
(
SStreamObj
*
pStream
,
SArray
*
pTaskList
,
SMnode
*
pMnode
,
int32_t
vgId
,
SVgObj
*
pVgroup
,
int32_t
fillHistory
)
{
SStreamTask
*
pTask
=
tNewStreamTask
(
pStream
->
uid
,
TASK_LEVEL__SINK
,
fillHistory
,
0
,
pTaskList
);
int64_t
uid
=
(
fillHistory
==
0
)
?
pStream
->
uid
:
pStream
->
hTaskUid
;
SStreamTask
*
pTask
=
tNewStreamTask
(
uid
,
TASK_LEVEL__SINK
,
fillHistory
,
0
,
pTaskList
);
if
(
pTask
==
NULL
)
{
terrno
=
TSDB_CODE_OUT_OF_MEMORY
;
return
-
1
;
...
...
@@ -335,8 +336,8 @@ static void setHTasksId(SArray* pTaskList, const SArray* pHTaskList) {
(
*
pHTask
)
->
streamTaskId
.
taskId
=
(
*
pStreamTask
)
->
id
.
taskId
;
(
*
pHTask
)
->
streamTaskId
.
streamId
=
(
*
pStreamTask
)
->
id
.
streamId
;
mDebug
(
"s-task:0x%
x related history task:0x%x, level:%d"
,
(
*
pStreamTask
)
->
id
.
taskId
,
(
*
pHTask
)
->
id
.
task
Id
,
(
*
pHTask
)
->
info
.
taskLevel
);
mDebug
(
"s-task:0x%
"
PRIx64
"-0x%x related history task:0x%"
PRIx64
"-0x%x, level:%d"
,
(
*
pStreamTask
)
->
id
.
stream
Id
,
(
*
p
StreamTask
)
->
id
.
taskId
,
(
*
pHTask
)
->
id
.
streamId
,
(
*
pHTask
)
->
id
.
taskId
,
(
*
p
HTask
)
->
info
.
taskLevel
);
}
}
...
...
source/dnode/snode/src/snode.c
浏览文件 @
4393375e
...
...
@@ -192,7 +192,8 @@ int32_t sndProcessTaskDropReq(SSnode *pSnode, char *msg, int32_t msgLen) {
int32_t
sndProcessTaskRunReq
(
SSnode
*
pSnode
,
SRpcMsg
*
pMsg
)
{
SStreamTaskRunReq
*
pReq
=
pMsg
->
pCont
;
SStreamTask
*
pTask
=
streamMetaAcquireTask
(
pSnode
->
pMeta
,
pReq
->
streamId
,
pReq
->
taskId
);
SStreamTask
*
pTask
=
streamMetaAcquireTask
(
pSnode
->
pMeta
,
pReq
->
streamId
,
pReq
->
taskId
);
if
(
pTask
)
{
streamProcessRunReq
(
pTask
);
streamMetaReleaseTask
(
pSnode
->
pMeta
,
pTask
);
...
...
@@ -246,8 +247,11 @@ int32_t sndProcessTaskRetrieveReq(SSnode *pSnode, SRpcMsg *pMsg) {
int32_t
sndProcessTaskDispatchRsp
(
SSnode
*
pSnode
,
SRpcMsg
*
pMsg
)
{
SStreamDispatchRsp
*
pRsp
=
POINTER_SHIFT
(
pMsg
->
pCont
,
sizeof
(
SMsgHead
));
int32_t
taskId
=
ntohl
(
pRsp
->
upstreamTaskId
);
SStreamTask
*
pTask
=
streamMetaAcquireTask
(
pSnode
->
pMeta
,
pRsp
->
streamId
,
taskId
);
int32_t
taskId
=
htonl
(
pRsp
->
upstreamTaskId
);
int64_t
streamId
=
htobe64
(
pRsp
->
streamId
);
SStreamTask
*
pTask
=
streamMetaAcquireTask
(
pSnode
->
pMeta
,
streamId
,
taskId
);
if
(
pTask
)
{
streamProcessDispatchRsp
(
pTask
,
pRsp
,
pMsg
->
code
);
streamMetaReleaseTask
(
pSnode
->
pMeta
,
pTask
);
...
...
@@ -255,7 +259,6 @@ int32_t sndProcessTaskDispatchRsp(SSnode *pSnode, SRpcMsg *pMsg) {
}
else
{
return
-
1
;
}
return
0
;
}
int32_t
sndProcessTaskRetrieveRsp
(
SSnode
*
pSnode
,
SRpcMsg
*
pMsg
)
{
...
...
source/dnode/vnode/src/tq/tq.c
浏览文件 @
4393375e
...
...
@@ -1072,8 +1072,9 @@ int32_t tqProcessStreamTaskCheckReq(STQ* pTq, SRpcMsg* pMsg) {
pTask
->
id
.
idStr
,
pStatus
,
rsp
.
reqId
,
rsp
.
upstreamTaskId
,
rsp
.
upstreamNodeId
,
rsp
.
status
);
}
else
{
rsp
.
status
=
0
;
tqDebug
(
"tq recv task check(taskId:0x%x not built yet) req(reqId:0x%"
PRIx64
") from task:0x%x (vgId:%d), rsp status %d"
,
taskId
,
rsp
.
reqId
,
rsp
.
upstreamTaskId
,
rsp
.
upstreamNodeId
,
rsp
.
status
);
tqDebug
(
"tq recv task check(taskId:0x%"
PRIx64
"-0x%x not built yet) req(reqId:0x%"
PRIx64
") from task:0x%x (vgId:%d), rsp status %d"
,
req
.
streamId
,
taskId
,
rsp
.
reqId
,
rsp
.
upstreamTaskId
,
rsp
.
upstreamNodeId
,
rsp
.
status
);
}
return
streamSendCheckRsp
(
pTq
->
pStreamMeta
,
&
req
,
&
rsp
,
&
pMsg
->
info
,
taskId
);
...
...
source/libs/stream/src/streamRecover.c
浏览文件 @
4393375e
...
...
@@ -802,7 +802,8 @@ void launchFillHistoryTask(SStreamTask* pTask) {
}
ASSERT
(
pTask
->
status
.
downstreamReady
==
1
);
qDebug
(
"s-task:%s start to launch related fill-history task:0x%x"
,
pTask
->
id
.
idStr
,
tId
);
qDebug
(
"s-task:%s start to launch related fill-history task:0x%"
PRIx64
"-0x%x"
,
pTask
->
id
.
idStr
,
pTask
->
historyTaskId
.
streamId
,
tId
);
// launch associated fill history task
streamLaunchFillHistoryTask
(
pTask
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录