You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "BiteTheDDDDt (via GitHub)" <gi...@apache.org> on 2026/05/14 11:36:24 UTC
[PR] [fix](be) Fix runtime filter crash with shared hash table [doris]
BiteTheDDDDt opened a new pull request, #63256:
URL: https://github.com/apache/doris/pull/63256
### What problem does this PR solve?
Issue Number: close #xxx
Related PR: #49556, #61768, #62056, #60563
Problem Summary: RQG on branch-4.1 can hit a BE SIGSEGV while publishing runtime filters from `HashJoinBuildSinkLocalState::close()`. The crash happens in `RuntimeFilterWrapper::set_state()` because the non-builder shared-hash-table runtime filter path can install a null shared wrapper.
Root cause:
1. Shared hash table broadcast joins keep runtime filter wrappers in `HashJoinBuildSinkOperatorX::_runtime_filters`.
2. If the builder task is terminated early, it skips runtime filter `build()` and never fills the shared wrapper map.
3. branch-4.1 still signaled non-builder tasks unconditionally from `close()`, so a non-builder could enter the shared runtime filter build path.
4. That path used `DCHECK(runtime_filters.contains(...))` plus `runtime_filters[filter_id]`; in release builds the DCHECK is disabled and `operator[]` inserts a null `shared_ptr`.
5. `RuntimeFilterProducer::set_wrapper_state_and_ready_to_publish()` then dereferences the null wrapper and crashes in `RuntimeFilterWrapper::set_state()`.
This PR backports the relevant safety from #62056 and the defensive checks from #60563 for branch-4.1: only signal non-builder tasks when the builder was not terminated, and return an error instead of inserting/null-dereferencing a missing shared runtime filter wrapper.
### Release note
Fixed a BE crash when publishing runtime filters for shared hash table hash joins.
### Check List (For Author)
- Test: Manual test
- build-support/check-format.sh
- 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: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [PR] [fix](be) Fix runtime filter crash with shared hash table [doris]
Posted by "yiguolei (via GitHub)" <gi...@apache.org>.
yiguolei commented on PR #63256:
URL: https://github.com/apache/doris/pull/63256#issuecomment-4458091080
skip buildall
--
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: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [PR] [fix](be) Fix runtime filter crash with shared hash table [doris]
Posted by "BiteTheDDDDt (via GitHub)" <gi...@apache.org>.
BiteTheDDDDt commented on PR #63256:
URL: https://github.com/apache/doris/pull/63256#issuecomment-4450390389
run buildall
--
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: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [PR] [fix](be) Fix runtime filter crash with shared hash table [doris]
Posted by "hello-stephen (via GitHub)" <gi...@apache.org>.
hello-stephen commented on PR #63256:
URL: https://github.com/apache/doris/pull/63256#issuecomment-4450314784
Thank you for your contribution to Apache Doris.
Don't know what should be done next? See [How to process your PR](https://cwiki.apache.org/confluence/display/DORIS/How+to+process+your+PR).
Please clearly describe your PR:
1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
3. What features were added. Why was this function added?
4. Which code was refactored and why was this part of the code refactored?
5. Which functions were optimized and what is the difference before and after the optimization?
--
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: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
Re: [PR] [fix](be) Fix runtime filter crash with shared hash table [doris]
Posted by "yiguolei (via GitHub)" <gi...@apache.org>.
yiguolei merged PR #63256:
URL: https://github.com/apache/doris/pull/63256
--
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: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org