List:Commits« Previous MessageNext Message »
From:Jonathan Miller Date:June 13 2007 5:52am
Subject:bk commit into 5.1 tree (jmiller:1.2488) BUG#28497
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of ndbdev. When ndbdev 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
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html

ChangeSet@stripped, 2007-06-13 05:52:43+02:00, jmiller@stripped +14 -0
  Updated patch for Bug#28497 based off of Magnus's review

  mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test@stripped, 2007-06-13 05:50:32+02:00,
jmiller@stripped +9 -9
    Updated to use new tool(s)

  mysql-test/extra/rpl_tests/rpl_loaddata.test@stripped, 2007-06-13 05:50:46+02:00,
jmiller@stripped +4 -4
    Updated to use new tool(s)

  mysql-test/extra/rpl_tests/rpl_row_tabledefs.test@stripped, 2007-06-13 05:50:56+02:00,
jmiller@stripped +5 -5
    Updated to use new tool(s)

  mysql-test/extra/rpl_tests/rpl_stm_000001.test@stripped, 2007-06-13 05:51:11+02:00,
jmiller@stripped +1 -1
    Updated to use new tool(s)

  mysql-test/extra/rpl_tests/rpl_stm_EE_err2.test@stripped, 2007-06-13 05:51:21+02:00,
jmiller@stripped +1 -1
    Updated to use new tool(s)

  mysql-test/include/wait_for_slave_io_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +33 -0
    Updated previous commit to include Magnus's change request from review. In addition, I
moved it from the mysql-5.1 to mysql-5.1-maint clone. We now have 3 new replications tools
and one tool that has been refactored. 1) include/wait_for_slave_to_stop.inc replaces the
old mysqltest.c wait_for_slave_to_stop. NEW: 2) include/wait_for_slave_sql_to_stop.inc is
for when you are expecting the slave to get an SQL error and waiting for the SQL Thread to
stop. 3) include/wait_for_slave_io_to_stop.inc is used for test that you expect sometype
of IO error and the IO Thread to stop. 4) include/wait_for_slave_to_start.inc for waiting
for the slave to completely start before moving forward in the test. All 4 tests have a
built in loop that will stop the test if any of the tools take too long.

  mysql-test/include/wait_for_slave_io_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +0 -0

  mysql-test/include/wait_for_slave_sql_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +30 -0
    Updated previous commit to include Magnus's change request from review. In addition, I
moved it from the mysql-5.1 to mysql-5.1-maint clone. We now have 3 new replications tools
and one tool that has been refactored. 1) include/wait_for_slave_to_stop.inc replaces the
old mysqltest.c wait_for_slave_to_stop. NEW: 2) include/wait_for_slave_sql_to_stop.inc is
for when you are expecting the slave to get an SQL error and waiting for the SQL Thread to
stop. 3) include/wait_for_slave_io_to_stop.inc is used for test that you expect sometype
of IO error and the IO Thread to stop. 4) include/wait_for_slave_to_start.inc for waiting
for the slave to completely start before moving forward in the test. All 4 tests have a
built in loop that will stop the test if any of the tools take too long.

  mysql-test/include/wait_for_slave_sql_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +0 -0

  mysql-test/include/wait_for_slave_to_start.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +35 -0
    Updated previous commit to include Magnus's change request from review. In addition, I
moved it from the mysql-5.1 to mysql-5.1-maint clone. We now have 3 new replications tools
and one tool that has been refactored. 1) include/wait_for_slave_to_stop.inc replaces the
old mysqltest.c wait_for_slave_to_stop. NEW: 2) include/wait_for_slave_sql_to_stop.inc is
for when you are expecting the slave to get an SQL error and waiting for the SQL Thread to
stop. 3) include/wait_for_slave_io_to_stop.inc is used for test that you expect sometype
of IO error and the IO Thread to stop. 4) include/wait_for_slave_to_start.inc for waiting
for the slave to completely start before moving forward in the test. All 4 tests have a
built in loop that will stop the test if any of the tools take too long.

  mysql-test/include/wait_for_slave_to_start.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +0 -0

  mysql-test/include/wait_for_slave_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +37 -0
    Updated previous commit to include Magnus's change request from review. In addition, I
moved it from the mysql-5.1 to mysql-5.1-maint clone. We now have 3 new replications tools
and one tool that has been refactored. 1) include/wait_for_slave_to_stop.inc replaces the
old mysqltest.c wait_for_slave_to_stop. NEW: 2) include/wait_for_slave_sql_to_stop.inc is
for when you are expecting the slave to get an SQL error and waiting for the SQL Thread to
stop. 3) include/wait_for_slave_io_to_stop.inc is used for test that you expect sometype
of IO error and the IO Thread to stop. 4) include/wait_for_slave_to_start.inc for waiting
for the slave to completely start before moving forward in the test. All 4 tests have a
built in loop that will stop the test if any of the tools take too long.

  mysql-test/include/wait_for_slave_to_stop.inc@stripped, 2007-06-13 05:41:56+02:00,
jmiller@stripped +0 -0

  mysql-test/t/rpl_critical_errors.test@stripped, 2007-06-13 05:43:36+02:00, jmiller@stripped
+1 -1
    Updated to use new tool(s)

  mysql-test/t/rpl_dual_pos_advance.test@stripped, 2007-06-13 05:46:45+02:00, jmiller@stripped
+1 -1
    Updated to use new tool(s)

  mysql-test/t/rpl_known_bugs_detection.test@stripped, 2007-06-13 05:47:22+02:00,
jmiller@stripped +2 -2
    Updated to use new tool(s)

  mysql-test/t/rpl_rotate_logs.test@stripped, 2007-06-13 05:47:36+02:00, jmiller@stripped +1
-1
    Updated to use new tool(s)

  mysql-test/t/rpl_row_inexist_tbl.test@stripped, 2007-06-13 05:48:11+02:00, jmiller@stripped
+1 -1
    Updated to use new tool(s)

# 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:	jmiller
# Host:	ndb08.mysql.com
# Root:	/data2/mysql-5.1-maint

--- 1.2/mysql-test/t/rpl_known_bugs_detection.test	2007-06-13 05:52:55 +02:00
+++ 1.3/mysql-test/t/rpl_known_bugs_detection.test	2007-06-13 05:52:55 +02:00
@@ -25,7 +25,7 @@
 INSERT INTO t1(b) VALUES(1),(1),(2) ON DUPLICATE KEY UPDATE t1.b=10;
 SELECT * FROM t1;
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_to_stop.inc
 # show the error message
 --replace_column 1 # 4 # 7 # 8 # 9 # 23 # 33 #
 --query_vertical show slave status;
@@ -79,7 +79,7 @@
 t1.field_3 = t2.field_c;
 SELECT * FROM t1;
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_to_stop.inc
 # show the error message
 --replace_column 1 # 4 # 7 # 8 # 9 # 23 # 33 #
 --query_vertical show slave status;

--- 1.2/mysql-test/t/rpl_dual_pos_advance.test	2007-06-13 05:52:55 +02:00
+++ 1.3/mysql-test/t/rpl_dual_pos_advance.test	2007-06-13 05:52:55 +02:00
@@ -61,7 +61,7 @@
 
 # select master_pos_wait("slave-bin.000001",137);
 
-# wait_for_slave_to_stop;
+# --source include/wait_for_slave_to_stop.inc
 
 # then BUG#13861 causes t3 to show up below (because stopped too
 # late).

--- 1.2/mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test	2007-06-13 05:52:55 +02:00
+++ 1.3/mysql-test/extra/rpl_tests/rpl_extraSlave_Col.test	2007-06-13 05:52:55 +02:00
@@ -138,7 +138,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -183,7 +183,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -228,7 +228,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -274,7 +274,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -427,7 +427,7 @@
 #connection slave;
 
 #--echo *** Select from T9 ***
-#wait_for_slave_to_stop;
+#--source include/wait_for_slave_sql_to_stop.inc
 #--replace_result $MASTER_MYPORT MASTER_PORT
 #--replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 #--query_vertical SHOW SLAVE STATUS
@@ -469,7 +469,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -513,7 +513,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -723,7 +723,7 @@
 --echo *** Expect slave to fail with Error 1060 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -832,7 +832,7 @@
 --echo *** Expect slave to fail with Error 1522 ***
 --echo ********************************************
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
--- New file ---
+++ mysql-test/include/wait_for_slave_io_to_stop.inc	07/06/13 05:41:56
###################################################
#Author: Jeb
#Date: 2007-06-11
#Purpose: used for io errors on the slave. If Slave gets an io
#         error, the io trhead should stop
#Details:
#      1) Fill in and setup variables
#      2) loop through looking for
#         sql threads to stop
#      3) If loops too long die.
####################################################
connection slave;
let $my_show= SHOW SLAVE STATUS;
let $sql_running= Slave_IO_Running;
let $row_number= 1;
let $run= 1;
let $counter= 300;

while ($run)
{
  let $io_result= query_get_value("SHOW SLAVE STATUS", Slave_IO_Running, $row_number);
  if (`SELECT '$io_result' = 'No'`){
    let $run= 0;
  }
  sleep 0.1;
  if (!$counter){
    --echo "Failed while waiting for slave IO thread to stop"
    SHOW SLAVE STATUS;
    exit;
  }
  dec $counter;
}


--- New file ---
+++ mysql-test/include/wait_for_slave_sql_to_stop.inc	07/06/13 05:41:56
###################################################
#Author: Jeb
#Date: 2007-06-11
#Purpose: used for SQL errors on the slave. If Slave gets a sql
#         error, the SQL trhead should stop
#Details:
#      1) Fill in and setup variables
#      2) loop through looking for
#         sql threads to stop
#      3) If loops too long die.
####################################################
connection slave;
let $row_number= 1;
let $run= 1;
let $counter= 300;

while ($run)
{
  let $sql_result= query_get_value("SHOW SLAVE STATUS", Slave_SQL_Running, $row_number);
  if (`SELECT '$sql_result' = 'No'`){
    let $run= 0;
  }
  sleep 0.1;
  if (!$counter){
   --echo "Failed while waiting for slave SQL thread to stop"
   SHOW SLAVE STATUS;
   exit;
  }
  dec $counter;
}

--- New file ---
+++ mysql-test/include/wait_for_slave_to_start.inc	07/06/13 05:41:56
###################################################
#Author: Jeb
#Date: 2007-06-11
#Purpose: To wait a brief time for slave to start
#Details:
#      1) Fill in and setup variables
#      2) loop through looking for both
#         io and sql threads to start
#      3) If loops too long die.
####################################################
connection slave;
let $row_number= 1;
let $run= 1;
let $counter= 300;

while ($run)
{
  let $io_result= query_get_value("SHOW SLAVE STATUS", Slave_IO_Running, $row_number);
  if (`SELECT '$io_result' = 'Yes'`){

    let $sql_result= query_get_value("SHOW SLAVE STATUS",  Slave_SQL_Running,
$row_number);
    if (`SELECT '$sql_result' = 'Yes'`){
      let $run= 0;
    }
  }
  sleep 0.1;
  if (!$counter){
    --echo "Failed while waiting for slave to start"
    SHOW SLAVE STATUS;
    exit;
  }
  dec $counter;
}



--- New file ---
+++ mysql-test/include/wait_for_slave_to_stop.inc	07/06/13 05:41:56
###################################################
#Author: Jeb
#Date: 2007-06-11
#Purpose: To replace the mysqltest.c executable 
#         wait_for_slave_to_stop function and
#         return this to the test language.
#Details:
#      1) Fill in and setup variables
#      2) loop through looking for both
#         io and sql threads to stop
#      3) If loops too long die.
####################################################
connection slave;
let $row_number= 1;
let $run= 1;
let $counter= 300;

while ($run)
{
  let $io_result= query_get_value("SHOW SLAVE STATUS", Slave_IO_Running, $row_number);
  if (`SELECT '$io_result' = 'No'`){

    let $sql_result= query_get_value("SHOW SLAVE STATUS", Slave_SQL_Running, $row_number);
    if (`SELECT '$sql_result' = 'No'`){
      let $run= 0;
    }
  }
  sleep 0.1;
  if (!$counter){
    --echo "Failed while waiting for slave to stop"
    SHOW SLAVE STATUS;
    exit;
  }
  dec $counter;
}




--- 1.3/mysql-test/extra/rpl_tests/rpl_stm_EE_err2.test	2007-06-13 05:52:55 +02:00
+++ 1.4/mysql-test/extra/rpl_tests/rpl_stm_EE_err2.test	2007-06-13 05:52:55 +02:00
@@ -24,7 +24,7 @@
 drop table t1;
 save_master_pos;
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 # End of 4.1 tests
 

--- 1.8/mysql-test/extra/rpl_tests/rpl_loaddata.test	2007-06-13 05:52:55 +02:00
+++ 1.9/mysql-test/extra/rpl_tests/rpl_loaddata.test	2007-06-13 05:52:55 +02:00
@@ -68,7 +68,7 @@
 save_master_pos;
 connection slave;
 # The SQL slave thread should be stopped now.
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 # Skip the bad event and see if error is cleared in SHOW SLAVE STATUS by START
 # SLAVE, even though we are not executing any event (as sql_slave_skip_counter
@@ -93,7 +93,7 @@
 # The SQL slave thread should be stopped now. 
 # Exec_Master_Log_Pos should point to the start of Execute event
 # for last load data.
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 # CHANGE MASTER and see if error is cleared in SHOW SLAVE STATUS.
 stop slave;
@@ -116,7 +116,7 @@
 save_master_pos;
 connection slave;
 # The SQL slave thread should be stopped now.
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 # RESET SLAVE and see if error is cleared in SHOW SLAVE STATUS.
 stop slave;
@@ -152,7 +152,7 @@
 terminated by ',' optionally enclosed by '%' escaped by '@' lines terminated by
 '\n##\n' starting by '>' ignore 1 lines;
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 drop table t2;
 connection master;
 drop table t2;

--- 1.7/mysql-test/extra/rpl_tests/rpl_row_tabledefs.test	2007-06-13 05:52:55 +02:00
+++ 1.8/mysql-test/extra/rpl_tests/rpl_row_tabledefs.test	2007-06-13 05:52:55 +02:00
@@ -113,7 +113,7 @@
 connection master;
 INSERT INTO t1_nodef VALUES (1,2);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -127,7 +127,7 @@
 connection master;
 INSERT INTO t2 VALUES (2,4);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -141,7 +141,7 @@
 connection master;
 INSERT INTO t4 VALUES (4);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -155,7 +155,7 @@
 connection master;
 INSERT INTO t5 VALUES (5,10,25);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS
@@ -169,7 +169,7 @@
 connection master;
 INSERT INTO t6 VALUES (6,12,36);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 --replace_result $MASTER_MYPORT MASTER_PORT
 --replace_column 1 # 7 # 8 # 9 # 22 # 23 # 33 #
 --query_vertical SHOW SLAVE STATUS

--- 1.2/mysql-test/t/rpl_row_inexist_tbl.test	2007-06-13 05:52:55 +02:00
+++ 1.3/mysql-test/t/rpl_row_inexist_tbl.test	2007-06-13 05:52:55 +02:00
@@ -23,7 +23,7 @@
 
 connection slave;
 # slave should have stopped because can't find table t1
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 # see if we have a good error message:
 --replace_result $MASTER_MYPORT MASTER_MYPORT
 --replace_column 1 # 7 # 8 # 9 # 23 # 33 #

--- 1.1/mysql-test/t/rpl_critical_errors.test	2007-06-13 05:52:55 +02:00
+++ 1.2/mysql-test/t/rpl_critical_errors.test	2007-06-13 05:52:55 +02:00
@@ -53,7 +53,7 @@
 
 # Here the slave will only stop if the query above actually started
 # inserting some rows into t2. Otherwise, it will hang forever.
-wait_for_slave_to_stop;
+--source include/wait_for_slave_to_stop.inc
 
 # The following should be 0
 SELECT COUNT(*) FROM t2;

--- 1.47/mysql-test/extra/rpl_tests/rpl_stm_000001.test	2007-06-13 05:52:55 +02:00
+++ 1.48/mysql-test/extra/rpl_tests/rpl_stm_000001.test	2007-06-13 05:52:55 +02:00
@@ -98,7 +98,7 @@
 connection slave;
 # The SQL slave thread should now have stopped because the query was killed on
 # the master (so it has a non-zero error code in the binlog).
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 # The following test can't be done because the result of Pos will differ
 # on different computers

--- 1.71/mysql-test/t/rpl_rotate_logs.test	2007-06-13 05:52:55 +02:00
+++ 1.72/mysql-test/t/rpl_rotate_logs.test	2007-06-13 05:52:55 +02:00
@@ -96,7 +96,7 @@
 set insert_id=1234;
 insert into t2 values(NULL);
 connection slave;
-wait_for_slave_to_stop;
+--source include/wait_for_slave_sql_to_stop.inc
 
 #restart slave skipping one event
 set global sql_slave_skip_counter=1;
Thread
bk commit into 5.1 tree (jmiller:1.2488) BUG#28497Jonathan Miller13 Jun