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

*: fix oom action cancel bug #10993

Merged
merged 3 commits into from Jul 1, 2019

Conversation

@crazycs520
Copy link
Contributor

commented Jun 30, 2019

What problem does this PR solve?

set config.OOMAction = "cancel"
before this PR:

create table t1(a int primary key, b double);
insert into t1 values(3,2);

test> select sum(a) from t1 group by b;
+--------+
| sum(a) |
+--------+
| 3      |
+--------+
1 row in set
test> set @@tidb_mem_quota_query=1;
Query OK, 0 rows affected
test> select sum(a) from t1 group by b;
+--------+
| sum(a) |
+--------+
0 rows in set

After This PR:

test> select sum(a) from t1 group by b;
+--------+
| sum(a) |
+--------+
| 3      |
+--------+
1 row in set
Time: 0.006s
test> set @@tidb_mem_quota_query=1;
Query OK, 0 rows affected
Time: 0.001s
test> select sum(a) from t1 group by b;
(1105, u'Out Of Memory Quota![conn_id=1]')

What is changed and how it works?

Check List

Tests

  • Unit test

Code changes

  • Has exported function/method change

Side effects

Related changes

  • Need to cherry-pick to the release branch
@codecov

This comment has been minimized.

Copy link

commented Jun 30, 2019

Codecov Report

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

@@             Coverage Diff             @@
##             master     #10993   +/-   ##
===========================================
  Coverage   81.0758%   81.0758%           
===========================================
  Files           418        418           
  Lines         89473      89473           
===========================================
  Hits          72541      72541           
  Misses        11710      11710           
  Partials       5222       5222
@codecov

This comment has been minimized.

Copy link

commented Jun 30, 2019

Codecov Report

Merging #10993 into master will decrease coverage by 0.1508%.
The diff coverage is 100%.

@@               Coverage Diff                @@
##             master     #10993        +/-   ##
================================================
- Coverage   81.1318%   80.9809%   -0.1509%     
================================================
  Files           419        418         -1     
  Lines         90316      89237      -1079     
================================================
- Hits          73275      72265      -1010     
+ Misses        11784      11738        -46     
+ Partials       5257       5234        -23
@crazycs520

This comment has been minimized.

Copy link
Contributor Author

commented Jun 30, 2019

/run-all-tests

@crazycs520

This comment has been minimized.

Copy link
Contributor Author

commented Jul 1, 2019

@zz-jason zz-jason requested review from qw4990 and SunRunAway Jul 1, 2019

@zz-jason
Copy link
Member

left a comment

LGTM

@tiancaiamao

This comment has been minimized.

Copy link
Contributor

commented Jul 1, 2019

LGTM

@zz-jason

This comment has been minimized.

Copy link
Member

commented Jul 1, 2019

needs to be cherry-picked to release-2.1 and release-3.0

@zz-jason zz-jason merged commit 1916eff into pingcap:master Jul 1, 2019

5 of 6 checks passed

ci/circleci CircleCI is running your tests
Details
idc-jenkins-ci-tidb/build Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/build_check_race Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/check_dev Jenkins job succeeded.
Details
idc-jenkins-ci-tidb/check_dev_2 Jenkins job succeeded.
Details
license/cla Contributor License Agreement is signed.
Details

@zz-jason zz-jason added status/LGT2 and removed status/LGT1 labels Jul 1, 2019

crazycs520 added a commit to crazycs520/tidb that referenced this pull request Jul 1, 2019

crazycs520 added a commit to crazycs520/tidb that referenced this pull request Jul 1, 2019

winkyao added a commit that referenced this pull request Jul 2, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.