BiteTheDDDDt opened a new pull request, #64899:
URL: https://github.com/apache/doris/pull/64899
### What problem does this PR solve?
Issue Number: None
Related PR: None
Problem Summary: A runtime filter dependency can wake a pipeline task while
another thread is closing or finalizing the same task.
`HybridTaskScheduler::submit()` synchronously calls
`PipelineTask::is_blockable()` before enqueueing, and `is_blockable()` reads
`_sink` and `_operators`. After terminal close/finalize starts releasing those
resources, a late submit can dereference cleared task resources and crash.
This PR adds a small submit gate on `PipelineTask`. Terminal close/finalize
closes that gate under a dedicated lock, and `HybridTaskScheduler::submit()`
checks it under the same lock before calling `is_blockable()`. The lock only
covers the blockable check; it does not cover the actual queue submit.
### Release note
None
### Check List (For Author)
- Test: Unit Test / Static check
- `./run-be-ut.sh --run
--filter=PipelineTaskTest.TEST_FINALIZED_TASK_REJECTS_HYBRID_SUBMIT`
- `build-support/check-format.sh`
- `CLANG_TIDY_BINARY=/mnt/disk6/common/ldb_toolchain_028/bin/clang-tidy
build-support/run-clang-tidy.sh --base upstream/master --build-dir
be/ut_build_ASAN`
- `git diff --check`
- Behavior changed: No
- Does this need documentation: No
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]