MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:msvensson Date:October 18 2006 9:34pm
Subject:bk commit into 5.0 tree (msvensson:1.2312) BUG#22728
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of msvensson. When msvensson does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository

ChangeSet@stripped, 2006-10-18 23:34:30+02:00, msvensson@neptunus.(none) +2 -0
  Bug#22728 Handler_rollback value is growing
   - The handler_rollback value is not growing, but the testcase
  does not work as handler_rollback is not cleared by "flush status"
  Thus we need to record before and after value and do a compare  

  mysql-test/r/innodb_mysql.result@stripped, 2006-10-18 23:34:28+02:00, msvensson@neptunus.(none) +0 -4
    Update result

  mysql-test/t/innodb_mysql.test@stripped, 2006-10-18 23:34:28+02:00, msvensson@neptunus.(none) +22 -2
    FLUSH STATUS does not clear all status variables(at least not Handler_rollback)
    Change the test case to records the value before and after and do a compare to check that 
    handler_rollback has not changed

# This is a BitKeeper patch.  What follows are the unified diffs for the
# set of deltas contained in the patch.  The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User:	msvensson
# Host:	neptunus.(none)
# Root:	/home/msvensson/mysql/mysql-5.0-maint

--- 1.11/mysql-test/r/innodb_mysql.result	2006-10-18 23:34:35 +02:00
+++ 1.12/mysql-test/r/innodb_mysql.result	2006-10-18 23:34:35 +02:00
@@ -104,14 +104,10 @@
 DROP TABLE t1, t2;
-flush status;
 create table t1 (c1 int) engine=innodb;
 handler t1 open;
 handler t1 read first;
-show /*!50002 GLOBAL */ status like 'Handler_rollback';
-Variable_name	Value
-Handler_rollback	0
 drop table t1;
 End of 4.1 tests
 create table t1m (a int) engine=myisam;

--- 1.10/mysql-test/t/innodb_mysql.test	2006-10-18 23:34:35 +02:00
+++ 1.11/mysql-test/t/innodb_mysql.test	2006-10-18 23:34:35 +02:00
@@ -117,9 +117,18 @@
 SELECT `id1` FROM `t1` WHERE `id1` NOT IN (SELECT `id1` FROM `t2` WHERE `id2` = 1 AND `id3` = 2);
 DROP TABLE t1, t2;
 # Bug #22728 - Handler_rollback value is growing
-flush status;
+# flush status doesn't reset "handler_rollback in 5.0
+# to check that it hasn't been increased we need to record the value
+# before and compare it to the value after
+# Save value of Handler_rollback as tab separated string in "before_value"
+let $before_value= `show /*!50002 GLOBAL */ status like 'Handler_rollback'`;
 create table t1 (c1 int) engine=innodb;
 connect (con1,localhost,root,,);
 connect (con2,localhost,root,,);
@@ -128,11 +137,22 @@
 handler t1 read first;
 disconnect con2;
 connection con1;
-show /*!50002 GLOBAL */ status like 'Handler_rollback';
+# Get value of Handler_rollback as tab separated string in "after_value"
+let $after_value=`show /*!50002 GLOBAL */ status like 'Handler_rollback'`;
+# Send the value to MySQL Server which checks if the two strings are equal
+let $cmp_query_result= `select STRCMP("$before_value", "$after_value")`;
+if ($cmp_query_result)
+  die("The value of Handler_rollback changed");
 connection default;
 drop table t1;
 disconnect con1;
 --echo End of 4.1 tests
 # Bug #12882  	min/max inconsistent on empty table
bk commit into 5.0 tree (msvensson:1.2312) BUG#22728msvensson18 Oct