Merge pull request #27101 from taosdata/fix/syntax

fix(stream): send kill checkpoint trans msg before close task.
This commit is contained in:
Haojun Liao 2024-08-09 02:03:32 +08:00 committed by GitHub
commit c793aba958
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 14 additions and 0 deletions

View File

@ -1140,6 +1140,20 @@ void streamMetaNotifyClose(SStreamMeta* pMeta) {
taosMsleep(100);
}
streamMetaRLock(pMeta);
SArray* pTaskList = NULL;
int32_t code = streamMetaSendMsgBeforeCloseTasks(pMeta, &pTaskList);
if (code != TSDB_CODE_SUCCESS) {
// return code;
}
streamMetaRUnLock(pMeta);
if (pTaskList != NULL) {
taosArrayDestroy(pTaskList);
}
int64_t el = taosGetTimestampMs() - st;
stDebug("vgId:%d all stream tasks are not in timer, continue close, elapsed time:%" PRId64 " ms", pMeta->vgId, el);
}