Current Path : /home/usr.opt/mysql57/mysql-test/suite/rpl/t/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //home/usr.opt/mysql57/mysql-test/suite/rpl/t/rpl_master_pos_wait.test |
# # Check what happens when there is an error with parameters provided # to MASTER_POS_WAIT and when it timeouts. # --source include/not_group_replication_plugin.inc source include/master-slave.inc; --source include/sync_slave_sql_with_master.inc # Bug#18259359 # To fix sporadic failure due to improper cleanup. let $rpl_server_number= 1; source include/rpl_restart_server.inc; let $rpl_server_number= 2; source include/rpl_restart_server.inc; --connection slave --source include/start_slave.inc # # MASTER_POS_WAIT: Check if time-out is correctly handled. # select master_pos_wait('master-bin.999999',0,2); explain extended select master_pos_wait('master-bin.999999',0,2); # # MASTER_POS_WAIT (BUG#651): Check if it hangs when slave is # idle and STOP SLAVE is issued. # send select master_pos_wait('master-bin.999999',0); connection slave1; stop slave sql_thread; connection slave; reap; # # MASTER_POS_WAIT (BUG#26622): it does not work as documented # connection master; echo "*** must be empty ***"; query_vertical show slave status; echo "*** must be NULL ***"; select master_pos_wait('foo', 98); # # Bug#24976304 WAIT_UNTIL_SQL_THREAD_AFTER_GTIDS TIMEOUT VALUE HANDLES SOME # INPUTS BADLY # connection slave; --source include/start_slave_sql.inc --echo Test MASTER_POS_WAIT function with negative timeout value. --echo When SQL_MODE is strict, then it will throw WRONG_ARGUMENTS --echo error. SET @save_sql_mode=@@SESSION.SQL_MODE; SET @@SESSION.SQL_MODE="STRICT_ALL_TABLES"; --error ER_WRONG_ARGUMENTS SELECT MASTER_POS_WAIT('master-bin.999999', 4, -1); #--echo When SQL_MODE is non-strict mode, then it will return NULL immediately #--echo without doing any work and generates WRONG_ARGUMENTS warning. SET @@SESSION.SQL_MODE=""; SELECT MASTER_POS_WAIT('master-bin.999999', 4, -1); SET @@SESSION.SQL_MODE=@save_sql_mode; --echo Test WAIT_FOR_EXECUTED_GTID_SET function with fractional timeout value. --echo Earlier(before fix), 0.4 is read as integer value '0' and the function --echo hanged forever (or till all the specified gtids are executed). --echo Now(after fix) 0.4 will be read as doube 0.4 and will waitfor --echo atleast 0.4 seconds (or till all the specified gtids are executed). --echo Also check that in case of timeout, function returns -1. --let $assert_text= MASTER_POS_WAIT returns -1 if the timeout has been exceeded. --let $query_result= query_get_value("SELECT MASTER_POS_WAIT('master-bin.999999', 4, 0.4) AS VALUE", VALUE, 1) --let $assert_cond= "$query_result" = "-1" --source include/assert.inc # End of Test Bug#24976304 # End of 4.1 tests --let $rpl_only_running_threads= 1 --source include/rpl_end.inc