Merge lp:~laurynas-biveinis/percona-server/bug1188168-5.1 into lp:percona-server/5.1

Proposed by Laurynas Biveinis
Status: Merged
Approved by: Laurynas Biveinis
Approved revision: no longer in the source branch.
Merged at revision: 595
Proposed branch: lp:~laurynas-biveinis/percona-server/bug1188168-5.1
Merge into: lp:percona-server/5.1
Diff against target: 59 lines (+39/-0)
3 files modified
Percona-Server/mysql-test/r/percona_innodb_fake_changes_bug_1188168.result (+12/-0)
Percona-Server/mysql-test/t/percona_innodb_fake_changes_bug_1188168.test (+23/-0)
Percona-Server/storage/innodb_plugin/row/row0ins.c (+4/-0)
To merge this branch: bzr merge lp:~laurynas-biveinis/percona-server/bug1188168-5.1
Reviewer Review Type Date Requested Status
Sergei Glushchenko (community) g2 Approve
Review via email: mp+175185@code.launchpad.net

Description of the change

No BT or ST but blocks BT 20439.

http://jenkins.percona.com/job/percona-server-5.1-param/561/

    Fix bug 1188168 (Fake changes assertion fail in
    row_ins_clust_index_entry_by_modify() |
    btr_store_big_rec_extern_fields ()).

    The issue is caused that fake changes, while normally skipping the
    write of externally-stored columns, failed to so for one path in
    row_ins_index_entry_low(). Adjust accordingly and add a regression
    testcase.

To post a comment you must log in.
Revision history for this message
Sergei Glushchenko (sergei.glushchenko) wrote :

Approve

review: Approve (g2)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== added file 'Percona-Server/mysql-test/r/percona_innodb_fake_changes_bug_1188168.result'
--- Percona-Server/mysql-test/r/percona_innodb_fake_changes_bug_1188168.result 1970-01-01 00:00:00 +0000
+++ Percona-Server/mysql-test/r/percona_innodb_fake_changes_bug_1188168.result 2013-07-17 03:43:40 +0000
@@ -0,0 +1,12 @@
1DROP TABLE IF EXISTS t1;
2CREATE TABLE t1(id INT NOT NULL PRIMARY KEY, data TEXT) ENGINE=InnoDB;
3INSERT INTO t1 VALUES(1, '');
4INSERT INTO t1 VALUES(2, '');
5INSERT INTO t1 VALUES(3, '');
6INSERT INTO t1 VALUES(4, '');
7DELETE FROM t1 WHERE id = 4;
8SET innodb_fake_changes=1;
9INSERT INTO t1 VALUES (4, LPAD('a', 12000, 'b'));
10ERROR HY000: Got error 131 during COMMIT
11SET innodb_fake_changes=0;
12DROP TABLE t1;
013
=== added file 'Percona-Server/mysql-test/t/percona_innodb_fake_changes_bug_1188168.test'
--- Percona-Server/mysql-test/t/percona_innodb_fake_changes_bug_1188168.test 1970-01-01 00:00:00 +0000
+++ Percona-Server/mysql-test/t/percona_innodb_fake_changes_bug_1188168.test 2013-07-17 03:43:40 +0000
@@ -0,0 +1,23 @@
1--source include/have_innodb_plugin.inc
2
3--disable_warnings
4DROP TABLE IF EXISTS t1;
5--enable_warnings
6
7CREATE TABLE t1(id INT NOT NULL PRIMARY KEY, data TEXT) ENGINE=InnoDB;
8
9INSERT INTO t1 VALUES(1, '');
10INSERT INTO t1 VALUES(2, '');
11INSERT INTO t1 VALUES(3, '');
12INSERT INTO t1 VALUES(4, '');
13
14DELETE FROM t1 WHERE id = 4;
15
16SET innodb_fake_changes=1;
17
18--error ER_ERROR_DURING_COMMIT
19INSERT INTO t1 VALUES (4, LPAD('a', 12000, 'b'));
20
21SET innodb_fake_changes=0;
22
23DROP TABLE t1;
024
=== modified file 'Percona-Server/storage/innodb_plugin/row/row0ins.c'
--- Percona-Server/storage/innodb_plugin/row/row0ins.c 2013-05-23 09:09:56 +0000
+++ Percona-Server/storage/innodb_plugin/row/row0ins.c 2013-07-17 03:43:40 +0000
@@ -2127,6 +2127,10 @@
21272127
2128 if (big_rec) {2128 if (big_rec) {
2129 ut_a(err == DB_SUCCESS);2129 ut_a(err == DB_SUCCESS);
2130 if (UNIV_UNLIKELY(thr_get_trx(thr)->
2131 fake_changes)) {
2132 goto stored_big_rec;
2133 }
2130 /* Write out the externally stored2134 /* Write out the externally stored
2131 columns while still x-latching2135 columns while still x-latching
2132 index->lock and block->lock. Allocate2136 index->lock and block->lock. Allocate

Subscribers

People subscribed via source and target branches