Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

session: set EnableWindowFunction for all SessionVars #55991

Merged

Conversation

winoros
Copy link
Member

@winoros winoros commented Sep 10, 2024

What problem does this PR solve?

Issue Number: close #55981

Problem Summary:

What changed and how does it work?

Some internal sessions may not set EnableWindowFunction correctly.
As a result, the binding containing window functions might fail at <=v6.5.10 and <=v7.5.3 and <=v7.1.5

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-triage-completed release-note-none Denotes a PR that doesn't merit a release note. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Sep 10, 2024
@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Sep 10, 2024
@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-triage-completed lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 10, 2024
Copy link

ti-chi-bot bot commented Sep 10, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-09-10 16:08:00.278750517 +0000 UTC m=+372550.019174476: ☑️ agreed by hawkingrei.
  • 2024-09-10 16:08:20.432273576 +0000 UTC m=+372570.172697508: ☑️ agreed by jackysp.

@winoros
Copy link
Member Author

winoros commented Sep 10, 2024

/check-issue-triage-complete

Copy link

ti-chi-bot bot commented Sep 10, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hawkingrei, jackysp, yudongusa

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

The pull request process is described here

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 the approved label Sep 10, 2024
winoros added a commit to winoros/tidb that referenced this pull request Sep 10, 2024
@ti-chi-bot ti-chi-bot bot added needs-cherry-pick-release-8.1 Should cherry pick this PR to release-8.1 branch. needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. needs-cherry-pick-release-7.1 Should cherry pick this PR to release-7.1 branch. needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. needs-cherry-pick-release-6.5 Should cherry pick this PR to release-6.5 branch. labels Sep 10, 2024
winoros added a commit to winoros/tidb that referenced this pull request Sep 10, 2024
winoros added a commit to winoros/tidb that referenced this pull request Sep 10, 2024
Copy link

codecov bot commented Sep 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 56.4975%. Comparing base (f9c4773) to head (ae1ae38).
Report is 13 commits behind head on master.

Additional details and impacted files
@@                Coverage Diff                @@
##             master     #55991         +/-   ##
=================================================
- Coverage   72.9463%   56.4975%   -16.4488%     
=================================================
  Files          1605       1730        +125     
  Lines        446061     628133     +182072     
=================================================
+ Hits         325385     354880      +29495     
- Misses       100628     249310     +148682     
- Partials      20048      23943       +3895     
Flag Coverage Δ
integration 37.2651% <100.0000%> (?)
unit 72.0530% <100.0000%> (+<0.0001%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 52.9567% <ø> (ø)
parser ∅ <ø> (∅)
br 52.8673% <ø> (+7.0859%) ⬆️

@winoros winoros removed the needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. label Sep 10, 2024
@ti-chi-bot ti-chi-bot bot added needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. labels Sep 10, 2024
@winoros
Copy link
Member Author

winoros commented Sep 10, 2024

/test check_dev_2

Copy link

ti-chi-bot bot commented Sep 10, 2024

@winoros: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pull-br-integration-test
  • /test pull-integration-ddl-test
  • /test pull-lightning-integration-test
  • /test pull-mysql-client-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test canary-notify-when-compatibility-sections-changed
  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-nodejs-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test
  • pingcap/tidb/pull_integration_ddl_test
  • pingcap/tidb/pull_mysql_client_test

In response to this:

/test check_dev_2

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/test-infra repository.

Copy link

tiprow bot commented Sep 10, 2024

@winoros: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test tidb_parser_test

Use /test all to run all jobs.

In response to this:

/test check_dev_2

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.

@winoros
Copy link
Member Author

winoros commented Sep 10, 2024

/test check-dev2

Copy link

tiprow bot commented Sep 10, 2024

@winoros: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test fast_test_tiprow
  • /test tidb_parser_test

Use /test all to run all jobs.

In response to this:

/test check-dev2

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.

@ti-chi-bot ti-chi-bot bot merged commit 2c30f86 into pingcap:master Sep 10, 2024
23 checks passed
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-6.1: #55996.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Sep 10, 2024
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Sep 10, 2024
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-6.5: #55997.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Sep 10, 2024
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.1: #55998.

@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-7.5: #55999.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Sep 10, 2024
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
@ti-chi-bot
Copy link
Member

In response to a cherrypick label: new pull request created to branch release-8.1: #56000.

ti-chi-bot pushed a commit to ti-chi-bot/tidb that referenced this pull request Sep 10, 2024
Signed-off-by: ti-chi-bot <ti-community-prow-bot@tidb.io>
@winoros winoros deleted the set-enable-window-function-for-all-sessvar branch September 10, 2024 17:49
Benjamin2037 pushed a commit to Benjamin2037/tidb that referenced this pull request Sep 11, 2024
@ti-chi-bot ti-chi-bot bot removed the needs-cherry-pick-release-7.5 Should cherry pick this PR to release-7.5 branch. label Sep 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. needs-cherry-pick-release-6.5 Should cherry pick this PR to release-6.5 branch. needs-cherry-pick-release-7.1 Should cherry pick this PR to release-7.1 branch. needs-cherry-pick-release-8.1 Should cherry pick this PR to release-8.1 branch. release-note-none Denotes a PR that doesn't merit a release note. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Internal session cannot parse SQLs containing window functions
5 participants