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

Revert "executor: fix show global variables return session variables also (#19341)" #26258

Merged
merged 4 commits into from
Sep 3, 2021

Conversation

bb7133
Copy link
Member

@bb7133 bb7133 commented Jul 15, 2021

This reverts commit cc7a383..

What problem does this PR solve?

Issue Number: close #24326 for TiDB v5.0

Problem Summary:

  • Manual test (add detailed scripts or steps below)

The following code is used to do the tests:

       Class.forName("com.mysql.jdbc.Driver").newInstance();    
        String url = "jdbc:mysql://address=(protocol=tcp)(host=127.0.0.1)(port=4000)(user=root)/test?allowMultiQueries=true";    
        Connection conn = DriverManager.getConnection(url, "", "");    
        DatabaseMetaData meta = conn.getMetaData();    
        System.out.println("Driver version: " + meta.getDriverVersion());  

        int connId = 0;    
        while (connId < 20) {    
            try {    
                long startTime = System.currentTimeMillis();    
                conn = DriverManager.getConnection(url, "", "");    
                long duration = System.currentTimeMillis() - startTime;    
                System.out.println("Time for onConnection #" + connId + ": " + duration);    
                connId ++;    
            } catch (Exception e) {    
                System.out.println("Exception: "+e);    
                e.printStackTrace();    
            } finally {    
                conn.close();
            }
        }

After reverting the commit, duration of connection reduced.

Side effects

Documentation

  • To be added

Release note

@bb7133 bb7133 requested a review from a team as a code owner July 15, 2021 03:13
@bb7133 bb7133 requested review from wshwsh12 and removed request for a team July 15, 2021 03:13
@ti-chi-bot
Copy link
Member

ti-chi-bot commented Jul 15, 2021

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • djshow832
  • morgo

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

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

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added do-not-merge/cherry-pick-not-approved size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 15, 2021
@github-actions github-actions bot added the sig/execution SIG execution label Jul 15, 2021
@wshwsh12 wshwsh12 removed their request for review July 16, 2021 02:52
@bb7133
Copy link
Member Author

bb7133 commented Aug 10, 2021

/run-integration-test

@djshow832 djshow832 added the sig/sql-infra SIG: SQL Infra label Aug 31, 2021
@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Aug 31, 2021
@zhouqiang-cl zhouqiang-cl added the cherry-pick-approved Cherry pick PR approved by release team. label Sep 1, 2021
@bb7133
Copy link
Member Author

bb7133 commented Sep 2, 2021

/run-integration_test

@bb7133
Copy link
Member Author

bb7133 commented Sep 2, 2021

/rebuild

@ti-chi-bot ti-chi-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Sep 2, 2021
@bb7133 bb7133 force-pushed the bb7133/revert_19341 branch 2 times, most recently from 818865d to 81f8d1f Compare September 2, 2021 13:14
@bb7133
Copy link
Member Author

bb7133 commented Sep 2, 2021

PTAL @morgo , the revert work is not trivial because of some succeeding PRs(#21988, #22284...)

@morgo morgo self-requested a review September 3, 2021 00:14
@morgo morgo added the compatibility-breaker Violation of forwards/backwards compatibility in a design-time piece. label Sep 3, 2021
Copy link
Contributor

@morgo morgo left a comment

Choose a reason for hiding this comment

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

LGTM, but I've added the compatibility breaker tag. I think we should change the compatibility message to:

  • The output of SHOW VARIABLES now only includes session scoped variables. This change was introduced to address a performance issue; in TiDB 5.1 and above the output of SHOW VARIABLES returns all variables again.

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Sep 3, 2021
@bb7133
Copy link
Member Author

bb7133 commented Sep 3, 2021

LGTM, but I've added the compatibility breaker tag. I think we should change the compatibility message to:

  • The output of SHOW VARIABLES now only includes session scoped variables. This change was introduced to address a performance issue; in TiDB 5.1 and above the output of SHOW VARIABLES returns all variables again.

Thank you!

@djshow832
Copy link
Contributor

/merge

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Sep 3, 2021
@djshow832
Copy link
Contributor

/merge cancel

@ti-chi-bot ti-chi-bot removed the status/can-merge Indicates a PR has been approved by a committer. label Sep 3, 2021
@djshow832
Copy link
Contributor

/merge

@ti-chi-bot
Copy link
Member

This pull request has been accepted and is ready to merge.

Commit hash: afcf2e8

@ti-chi-bot ti-chi-bot added the status/can-merge Indicates a PR has been approved by a committer. label Sep 3, 2021
@ti-chi-bot
Copy link
Member

@bb7133: Your PR was out of date, I have automatically updated it for you.

At the same time I will also trigger all tests for you:

/run-all-tests

If the CI test fails, you just re-trigger the test that failed and the bot will merge the PR for you after the CI passes.

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 ti-community-infra/tichi repository.

@ti-chi-bot ti-chi-bot merged commit 14ac993 into pingcap:release-5.0 Sep 3, 2021
@zhouqiang-cl zhouqiang-cl added this to the v5.0.4 milestone Sep 10, 2021
@bb7133 bb7133 deleted the bb7133/revert_19341 branch December 29, 2023 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cherry-pick-approved Cherry pick PR approved by release team. compatibility-breaker Violation of forwards/backwards compatibility in a design-time piece. sig/execution SIG execution sig/sql-infra SIG: SQL Infra size/L Denotes a PR that changes 100-499 lines, ignoring generated files. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants