Merge pull request #22353 from taosdata/fix/liaohj

fix(stream): commit the update to make sure the new state of tasks will be persistent to disk.
This commit is contained in:
Haojun Liao 2023-08-07 22:57:08 +08:00 committed by GitHub
commit 85756e4404
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -502,11 +502,13 @@ int32_t streamProcessScanHistoryFinishRsp(SStreamTask* pTask) {
taosWLockLatch(&pMeta->lock);
streamMetaSaveTask(pMeta, pTask);
streamMetaCommit(pMeta);
taosWUnLockLatch(&pMeta->lock);
// history data scan in the stream time window finished, now let's enable the pause
streamTaskEnablePause(pTask);
// for source tasks, let's continue execute.
if (pTask->info.taskLevel == TASK_LEVEL__SOURCE) {
streamSchedExec(pTask);
}