[fix](inverted index) catch IO exception to avoid coredump in inverted index string reader#51844
Conversation
…d index string reader
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
run buildall |
There was a problem hiding this comment.
Pull Request Overview
This PR adds error handling around CLucene interactions in the string inverted index reader to prevent core dumps on IO failures and introduces unit tests to verify that failures are correctly converted to error statuses.
- Wraps the search and cache logic in
StringTypeInvertedIndexReader::queryinside atry/catchforCLuceneErrorand logs the error. - Returns
INVERTED_INDEX_CLUCENE_ERRORinstead of crashing on IO exceptions. - Adds mock readers and new tests (
CacheErrorScenarios,TokenizedIndexQueryErrorScenarios) to cover both un-tokenized and tokenized index error paths.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| be/src/olap/rowset/segment_v2/inverted_index_reader.cpp | Wrapped query body in try/catch, added logging and status return on CLuceneError. |
| be/test/olap/rowset/segment_v2/inverted_index_reader_test.cpp | Added mocks to simulate CLucene IO failures and tests for both cache-enabled and tokenized queries. |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
run buildall |
TPC-H: Total hot run time: 34395 ms |
TPC-DS: Total hot run time: 185782 ms |
TPC-H: Total hot run time: 33825 ms |
TPC-DS: Total hot run time: 193001 ms |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
TPC-H: Total hot run time: 33662 ms |
TPC-DS: Total hot run time: 191581 ms |
ClickBench: Total hot run time: 29.71 s |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
|
PR approved by anyone and no changes requested. |
|
PR approved by at least one committer and no changes requested. |
…d index string reader (apache#51844) Problem Summary: This PR adds error handling around CLucene interactions in the string inverted index reader to prevent core dumps on IO failures and introduces.
…d index string reader (apache#51844) Problem Summary: This PR adds error handling around CLucene interactions in the string inverted index reader to prevent core dumps on IO failures and introduces.
What problem does this PR solve?
Issue Number: close #xxx
Related PR: #xxx
Problem Summary:
This PR adds error handling around CLucene interactions in the string inverted index reader to prevent core dumps on IO failures and introduces.
Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)