Skip to content

tiflash: document the TIFLASH_LM_FILTER optimizer hint - #24547

Open
windtalker wants to merge 2 commits into
pingcap:masterfrom
windtalker:docs/tiflash-lm-filter
Open

windtalker wants to merge 2 commits into
pingcap:masterfrom
windtalker:docs/tiflash-lm-filter

Conversation

@windtalker

@windtalker windtalker commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

What is changed, added, or deleted? (Required)

Document the TIFLASH_LM_FILTER optimizer hint so users can choose which TiFlash filter conditions participate in late materialization. Add syntax, query-block forms, column-matching rules, prerequisites, limitations, and usage examples that show how to verify the filter split with EXPLAIN.

The source code PR is still open and has no release milestone. An HTML TODO marks the introduction version for confirmation before merging.

Validation:

  • Markdown lint passed for both changed files.
  • Internal link and anchor checks passed for both changed files using the repository configuration.
  • git diff --check passed.

Which TiDB version(s) do your changes apply to? (Required)

Tips for choosing the affected version(s):

By default, CHOOSE MASTER ONLY so your changes will be applied to the next TiDB major or minor releases. If your PR involves a product feature behavior change or a compatibility change, CHOOSE THE AFFECTED RELEASE BRANCH(ES) AND MASTER.

For details, see tips for choosing the affected versions.

  • master (the latest development version)
  • v9.0 (TiDB 9.0 versions)
  • v8.5 (TiDB 8.5 versions)
  • v8.1 (TiDB 8.1 versions)
  • v7.5 (TiDB 7.5 versions)
  • v7.1 (TiDB 7.1 versions)
  • v6.5 (TiDB 6.5 versions)

What is the related PR or file link(s)?

AI agent involvement

  • The changes in this PR were primarily made by an AI agent on behalf of the PR author.

Do your changes match any of the following descriptions?

  • Delete files
  • Change aliases
  • Need modification after applied to another branch
  • Might cause conflicts after applied to another branch

Summary by CodeRabbit

  • Documentation
    • Added guidance for the TIFLASH_LM_FILTER optimizer hint, including how to select filters by referenced columns and what happens to conditions that do not match.
    • Documented the hint’s syntax, prerequisites, scan limitations, and behavior when parameters are missing or invalid, with examples for single- and multi-column filters and how to inspect results with EXPLAIN.

@ti-chi-bot

ti-chi-bot Bot commented Oct 26, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign jackysp for approval. For more information see the Code Review Process.
Please ensure that each of them provides their approval before proceeding.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot Bot added missing-translation-status This PR does not have translation status info. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 26, 2026
@coderabbitai

coderabbitai Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: pingcap/docs
  • Branch: master
  • File: .coderabbit.yaml
  • Commit: d6df199
  • Layers: Repository YAML
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: f506c524-2453-408e-940e-b9f6a7e8d257
Commits

Reviewing files that changed from the base of the PR and between b4169a9 and 184b3dc.

Files selected for processing: 2
  • optimizer-hints.md
  • tiflash/tiflash-late-materialization.md
Files with no reviewable changes: 1
  • optimizer-hints.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 2 remain after this review.

Walkthrough

The optimizer hints reference and TiFlash late-materialization guide now document the TIFLASH_LM_FILTER hint, its filter-selection behavior, syntax, examples, prerequisites, and limitations.

Changes: TIFLASH_LM_FILTER documentation

Layer / File(s) Summary
Hint syntax and behavior
optimizer-hints.md, tiflash/tiflash-late-materialization.md
Documents how the hint selects filters by referenced columns, affects cost-based selection, and handles prerequisites, limitations, and unmatched parameters. Includes usage examples and EXPLAIN guidance.

Priority: Normal

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Other

Suggested reviewers: qiancai

Merge Risk: Minimal · up to 184b3

The documentation-only change is mergeable pending normal documentation checks.

Pre-merge checks: Passed 5
Check name Status Explanation
Description check Passed The description explains the documentation changes, affected TiDB version, related PRs and issue, AI involvement, validation results, and version-specific considerations. The required sections are pre…
Title check Passed The title clearly and concisely identifies the main change: documenting the TIFLASH_LM_FILTER optimizer hint.
Docstring Coverage Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description explains the documentation changes, affected TiDB version, related PRs and issue, AI involvement, validation results, and version-specific considerations. The required sections are present and sufficiently complete.

Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (2 skipped: 2 unsupported.)

Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@ti-chi-bot

ti-chi-bot Bot commented Oct 26, 2026

Copy link
Copy Markdown

@qw4990: adding LGTM is restricted to approvers and reviewers in OWNERS files.

Details

In response to this:

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

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

Labels

missing-translation-status This PR does not have translation status info. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants