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

config: enable collect execution information by default #18415

Merged
merged 17 commits into from
Jul 13, 2020

Conversation

crazycs520
Copy link
Contributor

Signed-off-by: crazycs520 crazycs520@gmail.com

What problem does this PR solve?

related PR: #17573

Enable collect execution information by default, since the performance impact was small.

What is changed and how it works?

Related changes

  • Need to cherry-pick to the release branch

Check List

Tests

  • No code

Side effects

  • Performance regression
    • Consumes more CPU
    • Consumes more MEM

Release note

  • Enable collect execution information by default

Signed-off-by: crazycs520 <crazycs520@gmail.com>
@crazycs520
Copy link
Contributor Author

/bench

@pingcap pingcap deleted a comment from sre-bot Jul 10, 2020
@pingcap pingcap deleted a comment from sre-bot Jul 10, 2020
@crazycs520
Copy link
Contributor Author

/bench

@sre-bot
Copy link
Contributor

sre-bot commented Jul 10, 2020

Benchmark Report

Run Sysbench Performance Test on VMs

@@                               Benchmark Diff                               @@
================================================================================
--- tidb: af129d21160e3968e808ba2997351682b7b1775b
+++ tidb: 53c6ebcbe8903b5d13d30af6d6da672ef1a892fc
tikv: 3a4a0c98f9efc2b409add8cb6ac9e8886bb5730c
pd: 3910d2b0c4f68b13c32e3ce5136dfcf3a5c7560c
================================================================================
oltp_update_index:
    * QPS: 4945.10 ± 8.83% (std=264.36) delta: 4.56% (p=0.486)
    * Latency p50: 26.13 ± 6.22% (std=1.04) delta: -6.33%
    * Latency p99: 15.27 ± 0.00% (std=0.00) delta: -0.00%
            
oltp_insert:
    * QPS: 4845.06 ± 1.59% (std=62.22) delta: 6.24% (p=0.507)
    * Latency p50: 26.03 ± 9.60% (std=1.65) delta: -12.31%
    * Latency p99: 12.75 ± 0.00% (std=0.00) delta: -0.89%
            
oltp_read_write:
    * QPS: 8790.13 ± 4.28% (std=288.01) delta: -11.66% (p=0.410)
    * Latency p50: 281.17 ± 15.32% (std=26.26) delta: 4.98%
    * Latency p99: 191.54 ± 27.59% (std=39.28) delta: 21.39%
            
oltp_point_select:
    * QPS: 113486.05 ± 0.34% (std=229.15) delta: -0.62% (p=0.474)
    * Latency p50: 1.13 ± 0.00% (std=0.00) delta: 0.89%
    * Latency p99: 4.25 ± 0.00% (std=0.00) delta: 0.83%
            
oltp_update_non_index:
    * QPS: 6342.05 ± 2.39% (std=112.54) delta: 1.04% (p=0.432)
    * Latency p50: 19.64 ± 7.88% (std=0.96) delta: -4.53%
    * Latency p99: 12.98 ± 0.00% (std=0.00) delta: 0.00%
            

@crazycs520
Copy link
Contributor Author

/bench

@sre-bot
Copy link
Contributor

sre-bot commented Jul 13, 2020

Benchmark Report

Run Sysbench Performance Test on VMs

@@                               Benchmark Diff                               @@
================================================================================
--- tidb: 8a661044cedf8daad1de4fbf79a390962b6f6c3b
+++ tidb: dcfe047024046827da1b9463c26b3be9e318ba00
tikv: ddd571d9da5db1d14d701006259c551cc10dc2ba
pd: cb76a79a75ad0d7d2e7f1c27c07d7c2e6a66cac6
================================================================================
oltp_update_index:
    * QPS: 18276.90 ± 0.43% (std=56.99) delta: 10.46% (p=0.411)
    * Latency p50: 7.00 ± 0.43% (std=0.02) delta: -9.97%
    * Latency p99: 16.12 ± 0.00% (std=0.00) delta: 4.49%
            
oltp_insert:
    * QPS: 18951.72 ± 0.52% (std=68.24) delta: -0.73% (p=0.030)
    * Latency p50: 6.76 ± 0.30% (std=0.01) delta: 0.80%
    * Latency p99: 13.22 ± 0.00% (std=0.00) delta: 0.00%
            
oltp_read_write:
    * QPS: 36076.25 ± 0.18% (std=47.97) delta: -1.42% (p=0.070)
    * Latency p50: 71.75 ± 0.20% (std=0.11) delta: 1.42%
    * Latency p99: 125.52 ± 0.00% (std=0.00) delta: 0.90%
            
oltp_point_select:
    * QPS: 113199.43 ± 0.38% (std=349.37) delta: 0.19% (p=0.443)
    * Latency p50: 1.13 ± 0.00% (std=0.00) delta: 0.00%
    * Latency p99: 4.25 ± 0.00% (std=0.00) delta: 0.00%
            
oltp_update_non_index:
    * QPS: 23939.94 ± 0.11% (std=23.31) delta: -0.41% (p=0.129)
    * Latency p50: 5.34 ± 0.09% (std=0.00) delta: 0.42%
    * Latency p99: 13.70 ± 0.00% (std=0.00) delta: 0.88%
            

@crazycs520
Copy link
Contributor Author

crazycs520 commented Jul 13, 2020

Since the /bench result was not stable, I do a sysbench test by myself;

The cluster topology is 1*TiDB, 1*TiKV,1*PD, and deploy in 1 CDC machine.

Below is the result, as you can see, enable collect runtime information may has 0.2 ~ 3.2% performance impact. I think this is acceptable。

oltp_point_select

Disable Collect Runtime Info Enable Collect Runtime Info Delta
QPS 120.9 K 120.4 K -0.4%
Latency p50 0.305 ms 0.306 ms -0.3%
Latency p99 2.708 ms 2.714 ms -0.2%

oltp_read_only

Disable Collect Runtime Info Enable Collect Runtime Info Delta
QPS 64.6 K 62.9 K -2.6%
Latency p50 0.768 ms 0.786 ms -2.34%
Latency p99 6.03 ms 6.21 ms -2.99%

oltp_write_only

Disable Collect Runtime Info Enable Collect Runtime Info Delta
QPS 34.4 K 33.3 K -3.19%
Latency p50 1.52 ms 1.56 ms -2%
Latency p99 6.54 ms 6.61 ms -1.07%

Signed-off-by: crazycs520 <crazycs520@gmail.com>
@github-actions github-actions bot added the sig/sql-infra SIG: SQL Infra label Jul 13, 2020
@sre-bot
Copy link
Contributor

sre-bot commented Jul 13, 2020

Benchmark Report

Run Sysbench Performance Test on VMs

@@                               Benchmark Diff                               @@
================================================================================
--- tidb: b13fdb7bceaa671d37f06ace40a9d2da2af06966
+++ tidb: dcfe047024046827da1b9463c26b3be9e318ba00
tikv: ddd571d9da5db1d14d701006259c551cc10dc2ba
pd: cb76a79a75ad0d7d2e7f1c27c07d7c2e6a66cac6
================================================================================
oltp_update_index:
    * QPS: 17751.72 ± 6.85% (std=1101.39) delta: 0.02% (p=0.998)
    * Latency p50: 7.21 ± 6.03% (std=0.43) delta: 0.07%
    * Latency p99: 15.41 ± 0.91% (std=0.14) delta: -0.90%
            
oltp_insert:
    * QPS: 19005.34 ± 0.15% (std=18.74) delta: -0.04% (p=0.790)
    * Latency p50: 6.73 ± 0.10% (std=0.00) delta: 0.05%
    * Latency p99: 13.22 ± 0.00% (std=0.00) delta: 0.00%
            
oltp_read_write:
    * QPS: 35012.67 ± 0.20% (std=49.27) delta: -1.18% (p=0.000)
    * Latency p50: 73.93 ± 0.22% (std=0.11) delta: 1.18%
    * Latency p99: 128.97 ± 0.90% (std=1.16) delta: 0.91%
            
oltp_point_select:
    * QPS: 113589.34 ± 0.10% (std=79.87) delta: -0.30% (p=0.074)
    * Latency p50: 1.13 ± 0.00% (std=0.00) delta: 0.89%
    * Latency p99: 4.25 ± 0.00% (std=0.00) delta: 0.00%
            
oltp_update_non_index:
    * QPS: 23933.17 ± 0.17% (std=29.76) delta: -0.49% (p=0.006)
    * Latency p50: 5.35 ± 0.09% (std=0.00) delta: 0.42%
    * Latency p99: 13.70 ± 0.00% (std=0.00) delta: 0.88%
            

Copy link
Contributor

@SunRunAway SunRunAway left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-srebot ti-srebot added the status/LGT1 Indicates that a PR has LGTM 1. label Jul 13, 2020
@ti-srebot
Copy link
Contributor

@SunRunAway,Thanks for your review.

Copy link
Contributor

@djshow832 djshow832 left a comment

Choose a reason for hiding this comment

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

There's only session variable to control it. So when doing POC, it's hard to disable it.

Signed-off-by: crazycs520 <crazycs520@gmail.com>
@crazycs520 crazycs520 requested a review from a team as a code owner July 13, 2020 05:25
@crazycs520 crazycs520 requested review from XuHuaiyu and removed request for a team July 13, 2020 05:25
Copy link
Contributor

@djshow832 djshow832 left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-srebot ti-srebot removed the status/LGT1 Indicates that a PR has LGTM 1. label Jul 13, 2020
@ti-srebot
Copy link
Contributor

@djshow832,Thanks for your review.

@ti-srebot ti-srebot added the status/LGT2 Indicates that a PR has LGTM 2. label Jul 13, 2020
@crazycs520
Copy link
Contributor Author

/run-all-tests

@crazycs520
Copy link
Contributor Author

/rebuild

@codecov
Copy link

codecov bot commented Jul 13, 2020

Codecov Report

Merging #18415 into master will not change coverage.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             master     #18415   +/-   ##
===========================================
  Coverage   79.7620%   79.7620%           
===========================================
  Files           540        540           
  Lines        145257     145257           
===========================================
  Hits         115860     115860           
  Misses        20083      20083           
  Partials       9314       9314           

@crazycs520
Copy link
Contributor Author

/rebuild

@crazycs520
Copy link
Contributor Author

/rebuild

@crazycs520 crazycs520 merged commit 5574e1a into pingcap:master Jul 13, 2020
ti-srebot pushed a commit to ti-srebot/tidb that referenced this pull request Jul 13, 2020
Signed-off-by: ti-srebot <ti-srebot@pingcap.com>
@ti-srebot
Copy link
Contributor

cherry pick to release-4.0 in PR #18518

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/config sig/execution SIG execution sig/sql-infra SIG: SQL Infra status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants