Skip to content

[fix](regression-test) remove stale auto_broadcast_join_threshold from SET_VAR hints - #66332

Open
hulincup wants to merge 1 commit into
apache:masterfrom
hulincup:fix/remove-stale-auto-broadcast-join-threshold
Open

[fix](regression-test) remove stale auto_broadcast_join_threshold from SET_VAR hints#66332
hulincup wants to merge 1 commit into
apache:masterfrom
hulincup:fix/remove-stale-auto-broadcast-join-threshold

Conversation

@hulincup

Copy link
Copy Markdown

Motivation

PR #63744 removed the auto_broadcast_join_threshold session variable from SessionVariable.java (along with other deprecated/unused FE/BE configs and stale session variables).

Per Doris's removed-variable contract (documented in test_removed_session_variables.groovy), SET / SET_VAR on a removed variable name silently no-ops for BE-then-FE rolling-upgrade backward compatibility — it does not throw, and it does not configure anything.

Five regression-test suites still reference auto_broadcast_join_threshold=-1 inside /*+SET_VAR(...)*/ query hints, intending to disable auto-broadcast-join for those queries. Those hint entries are now silent no-ops: the tests believe they are configuring broadcast behavior, but the entry does nothing.

Change

Remove the stale auto_broadcast_join_threshold=-1 entries from the SET_VAR hints in the five affected suites. In every occurrence it is paired with broadcast_row_count_limit=0, which is still a valid session variable and — at 0 (no rows may broadcast) — already disables broadcast join. So removing the stale entry is behavior-preserving; broadcast_row_count_limit=0 continues to do the actual broadcast disabling.

The other variables in the hints (disable_join_reorder, disable_colocate_plan, ignore_storage_data_distribution, parallel_pipeline_task_num) are all confirmed still present in SessionVariable.java and are left untouched.

Files

  • regression-test/suites/nereids_p0/local_shuffle/test_local_shuffle_global_hash_require.groovy (4)
  • regression-test/suites/nereids_p0/local_shuffle/test_local_shuffle_rqg_bugs.groovy (4)
  • regression-test/suites/nereids_p0/local_shuffle/test_local_shuffle_fe_be_consistency.groovy (5)
  • regression-test/suites/nereids_p0/local_shuffle/test_local_shuffle_bucket_upgrade.groovy (1)
  • regression-test/suites/query_p0/join/test_multilevel_join_agg_local_shuffle.groovy (23)

Verification

  • Confirmed auto_broadcast_join_threshold is absent from SessionVariable.java on master (removed by [chore](conf) Remove deprecated/unused FE/BE configs and stale session variables #63744).
  • Confirmed broadcast_row_count_limit and the other hint vars are still present in SessionVariable.java.
  • grep auto_broadcast_join_threshold across the five files returns zero hits after the change.
  • No structural Groovy changes — only removal of a key=value, token from comma-separated lists inside SQL hint string literals.

Test plan

  • CI regression suites (nereids_p0/local_shuffle/*, query_p0/join/test_multilevel_join_agg_local_shuffle) pass unchanged — the removed hint entry was already a no-op, so test results are identical.

…m SET_VAR hints

PR apache#63744 removed the auto_broadcast_join_threshold session variable. Per
Doris's removed-variable contract (test_removed_session_variables.groovy), SET /
SET_VAR on removed names silently no-op for BE-then-FE rolling-upgrade compat.

Five regression-test suites still referenced auto_broadcast_join_threshold=-1
inside /*+SET_VAR(...)*/ query hints, intending to disable auto-broadcast-join.
Those entries are now silent no-ops. broadcast_row_count_limit=0 (still valid,
still set in every occurrence) already disables broadcast join, so removing the
stale entry is behavior-preserving.

Files:
- nereids_p0/local_shuffle/test_local_shuffle_global_hash_require.groovy
- nereids_p0/local_shuffle/test_local_shuffle_rqg_bugs.groovy
- nereids_p0/local_shuffle/test_local_shuffle_fe_be_consistency.groovy
- nereids_p0/local_shuffle/test_local_shuffle_bucket_upgrade.groovy
- query_p0/join/test_multilevel_join_agg_local_shuffle.groovy
@hello-stephen

Copy link
Copy Markdown
Contributor

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See 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?

@hulincup

Copy link
Copy Markdown
Author

Thanks for the checklist. Describing this PR per the points:

1. Problem fixed & how
PR #63744 removed the auto_broadcast_join_threshold session variable from SessionVariable.java. Per Doris's removed-variable contract (regression-test/suites/query_p0/set/test_removed_session_variables.groovy), SET / SET_VAR on a removed variable name silently no-ops for BE→FE rolling-upgrade compatibility — it neither throws nor configures anything. Five regression-test suites still carried auto_broadcast_join_threshold=-1 inside /*+SET_VAR(...)*/ query hints, intending to disable auto-broadcast-join, but those entries were silent no-ops. Removed the stale entries.

2. Behavior modified (previous vs. now, impact)

  • Previous: the auto_broadcast_join_threshold=-1 hint entry did nothing (already a no-op since [chore](conf) Remove deprecated/unused FE/BE configs and stale session variables #63744); broadcast_row_count_limit=0 (still a valid var, set in every occurrence) was what actually disabled broadcast join.
  • Now: the dead auto_broadcast_join_threshold=-1 entry is removed; broadcast_row_count_limit=0 is preserved, so broadcast join is still disabled exactly as before.
  • Impact: behavior-preserving. The removed entry had no effect at runtime; the tests' actual broadcast-disabling comes from broadcast_row_count_limit=0, which is unchanged. No query plan changes.

3. Features added — N/A.

4. Code refactored — N/A. Only regression-test .groovy suites; no production FE/BE code touched.

5. Functions optimized — N/A.

The other variables in the hints (disable_join_reorder, disable_colocate_plan, ignore_storage_data_distribution, parallel_pipeline_task_num) are confirmed still present in SessionVariable.java and were left untouched. CI verification: grep auto_broadcast_join_threshold across the five files returns zero hits after the change.

@shuke987

shuke987 commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

/review

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approval opinion: no blocking or actionable issues found.

Critical checkpoints:

  • Goal and correctness: all 37 stale auto_broadcast_join_threshold=-1 tokens are removed cleanly, and query behavior is preserved because that name already no-ops through VariableMgr.setVar. The surviving broadcast_row_count_limit=0, explicit join hints, and mandatory broadcast/replicated paths retain the intended local-shuffle plan categories.
  • Scope and clarity: the production behavior is unchanged and the five-file cleanup is small, focused, and mechanically consistent.
  • Concurrency, lifecycle, configuration, and compatibility implementation: no runtime code, shared state, configuration definition, persistence format, or rolling-upgrade implementation changes are introduced.
  • Parallel paths and tests: FE/BE and local-shuffle on/off query construction remains symmetric and ordered. The generic removed-name SET_VAR path remains exercised by surviving hints for another removed variable, while the dedicated compatibility suite retains exact-name standalone coverage. No .out change is expected because query results are unchanged.
  • Observability, transactions/data writes, FE-BE protocol, and performance: not affected by this test-only token cleanup.
  • Verification: static review only; the review contract forbids builds and test execution. No additional user-provided focus was supplied, so the whole PR was reviewed.

Review completion: complete after three bounded main-agent, full-coverage, and risk-focused convergence rounds; all candidates are resolved and no actionable finding remains.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants