Skip to content

docs: update PLAN REPLAYER object storage behavior#22549

Closed
zeminzhou wants to merge 6 commits intorelease-8.5from
docs/plan-replayer-object-storage-release-8.5
Closed

docs: update PLAN REPLAYER object storage behavior#22549
zeminzhou wants to merge 6 commits intorelease-8.5from
docs/plan-replayer-object-storage-release-8.5

Conversation

@zeminzhou
Copy link
Contributor

@zeminzhou zeminzhou commented Mar 10, 2026

Summary

Backport the PLAN REPLAYER documentation update to release-8.5.

  • document that PLAN REPLAYER can store generated files in the storage configured by tidb_cloud_storage_uri
  • clarify that PLAN REPLAYER DUMP returns either a file token or a presigned URL depending on the backend capability
  • document the corresponding download flow and presigned URL validity
  • clarify that PLAN REPLAYER CAPTURE files can also be stored in external storage while the token column still records the file token
  • update related system variable descriptions in system-variables.md

Reference

Testing

  • Not run (documentation only)

@ti-chi-bot
Copy link

ti-chi-bot bot commented Mar 10, 2026

[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 icemap 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 Mar 10, 2026
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request updates the documentation for the PLAN REPLAYER feature to reflect its enhanced integration with external object storage. The changes clarify how generated plan files are stored, retrieved, and managed when tidb_cloud_storage_uri is configured, providing users with comprehensive guidance on utilizing cloud storage for plan replayer outputs.

Highlights

  • External Storage Support for PLAN REPLAYER: Documented PLAN REPLAYER's support for storing generated files in external storage configured by tidb_cloud_storage_uri.
  • Flexible Output for PLAN REPLAYER DUMP: Clarified that PLAN REPLAYER DUMP can return either a file token or a presigned URL, depending on the storage backend's capabilities.
  • Enhanced Download Instructions: Provided detailed instructions for downloading PLAN REPLAYER DUMP files, including direct usage of presigned URLs.
  • PLAN REPLAYER CAPTURE Storage: Updated documentation to state that PLAN REPLAYER CAPTURE files can also be stored externally, while the token column continues to record the file token.
  • System Variable Updates: Revised system variable descriptions in system-variables.md to accurately reflect PLAN REPLAYER's new storage behaviors.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

Changelog
  • sql-plan-replayer.md
    • Added a section explaining that PLAN REPLAYER can store generated ZIP files in external storage if tidb_cloud_storage_uri is set.
    • Updated the description of PLAN REPLAYER DUMP's return value to specify it can be a presigned URL or a file token.
    • Included an example demonstrating a presigned URL as the output of PLAN REPLAYER DUMP.
    • Provided curl command examples for downloading files using presigned URLs.
    • Clarified the download process for PLAN REPLAYER CAPTURE files when external storage is used.
    • Revised notes on file retention periods to cover both local and external storage.
  • system-variables.md
    • Expanded the description of tidb_cloud_storage_uri to explicitly mention its use by PLAN REPLAYER for storing generated files.
    • Updated the description of tidb_last_plan_replayer_token to indicate that its result can be either a file token or a presigned URL.
Activity
  • This pull request is a backport of a documentation update to the release-8.5 branch.
  • The changes are purely documentation-related, so no testing was performed.
  • References to related mainline PRs (docs: update PLAN REPLAYER object storage behavior #22548, #65477, #65904, #66084) and the original commit (b9455277b9c3215b97624203b287adf3de8e3184) are provided.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the PLAN REPLAYER documentation to reflect its new capabilities with external object storage. The changes are well-written and significantly improve the accuracy and clarity of the documentation. I've included a few minor suggestions to align the text more closely with the repository's style guide, primarily focusing on using active voice and more direct phrasing for better readability.

Note: Security Review has been skipped due to the limited scope of the PR.

zeminzhou and others added 5 commits March 10, 2026 15:45
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@ti-chi-bot
Copy link

ti-chi-bot bot commented Mar 11, 2026

@hawkingrei: 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.

@hfxsd hfxsd added translation/doing This PR's assignee is translating this PR. v9.0-beta.3 This PR/issue applies to TiDB v9.0-beta.3. and removed missing-translation-status This PR does not have translation status info. labels Mar 11, 2026
```

The method of downloading the file of `PLAN REPLAYER CAPTURE` is the same as that of `PLAN REPLAYER`. For details, see [Examples of exporting cluster information](#examples-of-exporting-cluster-information).
If [`tidb_cloud_storage_uri`](/system-variables.md#tidb_cloud_storage_uri-new-in-v740) is configured, the captured file is also stored in the configured external storage. The `token` column still records the file token.

Choose a reason for hiding this comment

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

If tidb_cloud_storage_uri setted , what are the contents of column 'token'?

@hfxsd hfxsd removed the v9.0-beta.3 This PR/issue applies to TiDB v9.0-beta.3. label Mar 12, 2026
@zeminzhou zeminzhou closed this Mar 12, 2026
> **Note:**
>
> The `ZIP` file is stored in a TiDB cluster for at most one hour. After one hour, TiDB will delete it.
> TiDB keeps the result file for at most one hour. After one hour, TiDB deletes it from the corresponding local or external storage.

Choose a reason for hiding this comment

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

Will TiDB delete the result file on external storage after one hour ?

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

Labels

size/M Denotes a PR that changes 30-99 lines, ignoring generated files. translation/doing This PR's assignee is translating this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants