[refine](column) Make filter_by_selector const#65047
Conversation
|
Thank you for your contribution to Apache Doris. Please clearly describe your PR:
|
|
/review |
There was a problem hiding this comment.
Summary: I reviewed the full PR diff and surrounding lazy-materialization selector path for the column filter_by_selector const-correctness change. I did not find a blocking correctness issue or any evidence-backed inline finding to submit.
Critical checkpoint conclusions:
- Goal and proof: the PR makes the source-side
filter_by_selectorinterface const, updates the supported vector/decimal/string/dictionary/nullable implementations, removes the dictionary mutable scratch state, and updates BE unit tests to call through const source references. - Scope: the change is small and focused on the selector-filter interface and directly related tests.
- Concurrency/lifecycle: removing
ColumnDictI32::_stringsavoids per-column mutable scratch during selector filtering; I found no new shared lifecycle or locking requirement. - Config/session/compatibility: no new config, session variable, serialization format, or FE/BE protocol surface is introduced.
- Parallel paths: all visible supported
filter_by_selectoroverrides in the changed column classes match the new const base signature; unsupported columns still use the base error path. The production caller inSegmentIteratorobtains mutable or fresh destination columns before selector writes, including nullable nested-column writes. - Tests and validation: related BE unit tests were updated for const dispatch and nullable/dictionary/string behavior.
git diff --check 257417b029595580f6632b2e0fcf5e5ac3ccdb7d d71a5bb866b6163d9838ca4cbfcc057dc3133c26is clean. I did not run BE UTs/build because this runner lacksthirdparty/installedandcompile_commands.json.build-support/check-format.shwas attempted but failed before checking files becauseclang-formaton PATH is version 18 while the script requires version 16.
User focus: no additional review focus was provided.
Subagent conclusions: the optimizer/rewrite subagent found no candidates. The tests/session-config subagent found no candidates. In convergence round 1, both live subagents reviewed the final ledger/comment set with zero proposed inline comments and replied NO_NEW_VALUABLE_FINDINGS.
|
run buildall |
TPC-H: Total hot run time: 29609 ms |
TPC-DS: Total hot run time: 174585 ms |
ClickBench: Total hot run time: 25 s |
BE UT Coverage ReportIncrement line coverage Increment coverage report
|
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
|
run cloud_p0 |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
|
run cloud_p0 |
|
PR approved by at least one committer and no changes requested. |
|
PR approved by anyone and no changes requested. |
BE Regression && UT Coverage ReportIncrement line coverage Increment coverage report
|
What problem does this PR solve?
filter_by_selectorreads from the source column and writes selected rows into a destination column, so the source column should be accessed through a const interface. Root cause: the interface was non-const, andColumnNullable::filter_by_selectorwrote the destination nested column through aconst_caston the destination nullable internals. This change makes the interface const, updates the supported column implementations, removes the nullableconst_cast, and keepsColumnDictionaryread-only by using a local temporaryStringRefbuffer.Release note
None
Check List (For Author)
Test
Behavior changed:
Does this need documentation?
Check List (For Reviewer who merge this PR)