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/02/06 03:58:11 UTC
[PR] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
BiteTheDDDDt opened a new pull request, #60563:
URL: https://github.com/apache/doris/pull/60563
### What problem does this PR solve?
This pull request replaces many `DCHECK` assertions with explicit error handling throughout the runtime filter codebase. The changes improve robustness by converting failed internal assumptions into meaningful error statuses or exceptions, which helps prevent silent failures and makes debugging easier.
Error handling improvements for runtime filter logic:
* Replaced `DCHECK` assertions with status checks and error returns for null pointers, invalid states, and filter type mismatches in `runtime_filter.cpp`, `runtime_filter.h`, `runtime_filter_consumer.cpp`, `runtime_filter_mgr.cpp`, and `runtime_filter_producer.cpp`. This includes checks for serialization data, filter dependencies, and filter merge conditions. [[1]](diffhunk://#diff-f505841d01d9ca521e7c6780854dff8251e0ca047a0f03185f5e85bce4a6c181L65-R69) [[2]](diffhunk://#diff-54fe6a4b716938b750ec08983ee9ea7c9c390ffc8a796f361fd6354c3cb3a8c2L73-R77) [[3]](diffhunk://#diff-54fe6a4b716938b750ec08983ee9ea7c9c390ffc8a796f361fd6354c3cb3a8c2L92-R101) [[4]](diffhunk://#diff-de54918fd984e65b76a54152ed551c23348819b572d4253d577d6c9650bc95cbL117-R119) [[5]](diffhunk://#diff-de54918fd984e65b76a54152ed551c23348819b572d4253d577d6c9650bc95cbL134-R138) [[6]](diffhunk://#diff-de54918fd984e65b76a54152ed551c23348819b572d4253d577d6c9650bc95cbL203-R228) [[7]](diffhunk://#diff-5354bacdeccbd2d6f61cee8d820
6e6853f7505f353bfd33d556e05aba0a4db7fL129-R132) [[8]](diffhunk://#diff-5354bacdeccbd2d6f61cee8d8206e6853f7505f353bfd33d556e05aba0a4db7fL357-R364) [[9]](diffhunk://#diff-52614ca7b5c1da676f382429d3593900c0f2b449f57651f02cee47e72aa6736dL89-R93) [[10]](diffhunk://#diff-52614ca7b5c1da676f382429d3593900c0f2b449f57651f02cee47e72aa6736dL151-R158) [[11]](diffhunk://#diff-52614ca7b5c1da676f382429d3593900c0f2b449f57651f02cee47e72aa6736dL161-R171) [[12]](diffhunk://#diff-52614ca7b5c1da676f382429d3593900c0f2b449f57651f02cee47e72aa6736dL242-R255)
Error handling for producer and helper classes:
* Added error returns for invalid result column IDs and broadcast join conditions in `runtime_filter_producer_helper.cpp` and `runtime_filter_producer_helper_cross.h`. Checks ensure correct filter construction and insertion logic. [[1]](diffhunk://#diff-bddbf8ad6f2ca00f5bd80c7ff32db5ec5d57a8ceab20a80b72e9296ec5281d7eL77-R80) [[2]](diffhunk://#diff-bddbf8ad6f2ca00f5bd80c7ff32db5ec5d57a8ceab20a80b72e9296ec5281d7eL111-R132) [[3]](diffhunk://#diff-bddbf8ad6f2ca00f5bd80c7ff32db5ec5d57a8ceab20a80b72e9296ec5281d7eL150-R168) [[4]](diffhunk://#diff-c0909e54f288bc14f0c0057d7ea746384a62dfe8753d161b7d9d91eacc1859e9L54-R59)
Error handling for filter merging and assignment:
* Replaced assertions with error returns for filter state and type mismatches in `runtime_filter_wrapper.cpp` during merging. Added exceptions for failed string parsing in filter assignment for various types. Checks for null filter functions and parsing failures in min/max filter assignment. [[1]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL166-R176) [[2]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL291-R305) [[3]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL364-R383) [[4]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL375-R399) [[5]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL404-R433) [[6]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL419-R452) [[7]](diffhunk://#diff-d951fabc29ca512bccab5af3c0eb9ce9bc0d3a59585988014d6972e17fc0350cL459-R503)
### Check List (For Author)
- Test <!-- At least one of them must be included. -->
- [ ] Regression test
- [ ] Unit Test
- [ ] Manual test (add detailed scripts or steps below)
- [ ] No need to test or manual test. Explain why:
- [ ] This is a refactor/code format and no logic has been changed.
- [ ] Previous test can cover this change.
- [ ] No code files have been changed.
- [ ] Other reason <!-- Add your reason? -->
- Behavior changed:
- [ ] No.
- [ ] Yes. <!-- Explain the behavior change -->
- Does this need documentation?
- [ ] No.
- [ ] Yes. <!-- Add document PR link here. eg: https://github.com/apache/doris-website/pull/1214 -->
### Check List (For Reviewer who merge this PR)
- [ ] Confirm the release note
- [ ] Confirm test cases
- [ ] Confirm document
- [ ] Add branch pick label <!-- Add branch pick label that this PR should merge into -->
--
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "BiteTheDDDDt (via GitHub)" <gi...@apache.org>.
BiteTheDDDDt commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3857886929
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "BiteTheDDDDt (via GitHub)" <gi...@apache.org>.
BiteTheDDDDt commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3857831746
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "hello-stephen (via GitHub)" <gi...@apache.org>.
hello-stephen commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3857827003
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3882864905
PR approved by anyone and no changes requested.
--
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3882864740
PR approved by at least one committer and no changes requested.
--
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "hello-stephen (via GitHub)" <gi...@apache.org>.
hello-stephen commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3859896512
# BE Regression && UT Coverage Report
Increment line coverage `20.57% (36/175)` :tada:
[Increment coverage report](http://coverage.selectdb-in.cc/coverage/60563_2ca5147e0932e835d9c2196d1c0b66967b709364_merge/increment_report/index.html)
[Complete coverage report](http://coverage.selectdb-in.cc/coverage/60563_2ca5147e0932e835d9c2196d1c0b66967b709364_merge/report/index.html)
| Category | Coverage |
|-------------------|--------------------|
| Function Coverage | 73.30% (26500/36155) |
| Line Coverage | 56.40% (281406/498909) |
| Region Coverage | 54.06% (235273/435168) |
| Branch Coverage | 55.72% (101290/181800) |
--
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "hello-stephen (via GitHub)" <gi...@apache.org>.
hello-stephen commented on PR #60563:
URL: https://github.com/apache/doris/pull/60563#issuecomment-3859024475
# BE Regression && UT Coverage Report
Increment line coverage `20.57% (36/175)` :tada:
[Increment coverage report](http://coverage.selectdb-in.cc/coverage/60563_2ca5147e0932e835d9c2196d1c0b66967b709364_merge/increment_report/index.html)
[Complete coverage report](http://coverage.selectdb-in.cc/coverage/60563_2ca5147e0932e835d9c2196d1c0b66967b709364_merge/report/index.html)
| Category | Coverage |
|-------------------|--------------------|
| Function Coverage | 73.27% (26489/36155) |
| Line Coverage | 56.37% (281245/498909) |
| Region Coverage | 54.04% (235172/435168) |
| Branch Coverage | 55.68% (101232/181800) |
--
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] [Chore](runtime-filter) replace DCHECK/CHECK with Error Status or Exceptions [doris]
Posted by "BiteTheDDDDt (via GitHub)" <gi...@apache.org>.
BiteTheDDDDt merged PR #60563:
URL: https://github.com/apache/doris/pull/60563
--
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