mirror of
https://github.com/MariaDB/server.git
synced 2025-01-20 14:02:32 +01:00
5dcb0e447f
Conflicts: Text conflict in .bzr-mysql/default.conf Text conflict in mysql-test/extra/rpl_tests/rpl_loaddata.test Text conflict in mysql-test/r/mysqlbinlog2.result Text conflict in mysql-test/suite/binlog/r/binlog_stm_mix_innodb_myisam.result Text conflict in mysql-test/suite/binlog/r/binlog_unsafe.result Text conflict in mysql-test/suite/rpl/r/rpl_insert_id.result Text conflict in mysql-test/suite/rpl/r/rpl_loaddata.result Text conflict in mysql-test/suite/rpl/r/rpl_stm_auto_increment_bug33029.result Text conflict in mysql-test/suite/rpl/r/rpl_udf.result Text conflict in mysql-test/suite/rpl/t/rpl_slow_query_log.test Text conflict in sql/field.h Text conflict in sql/log.cc Text conflict in sql/log_event.cc Text conflict in sql/log_event_old.cc Text conflict in sql/mysql_priv.h Text conflict in sql/share/errmsg.txt Text conflict in sql/sp.cc Text conflict in sql/sql_acl.cc Text conflict in sql/sql_base.cc Text conflict in sql/sql_class.h Text conflict in sql/sql_db.cc Text conflict in sql/sql_delete.cc Text conflict in sql/sql_insert.cc Text conflict in sql/sql_lex.cc Text conflict in sql/sql_lex.h Text conflict in sql/sql_load.cc Text conflict in sql/sql_table.cc Text conflict in sql/sql_update.cc Text conflict in sql/sql_view.cc Conflict adding files to storage/innobase. Created directory. Conflict because storage/innobase is not versioned, but has versioned children. Versioned directory. Conflict adding file storage/innobase. Moved existing file to storage/innobase.moved. Conflict adding files to storage/innobase/handler. Created directory. Conflict because storage/innobase/handler is not versioned, but has versioned children. Versioned directory. Contents conflict in storage/innobase/handler/ha_innodb.cc
109 lines
2.8 KiB
Text
109 lines
2.8 KiB
Text
source include/have_semisync_plugin.inc;
|
|
source include/not_embedded.inc;
|
|
source include/master-slave.inc;
|
|
source include/have_innodb.inc;
|
|
|
|
let $engine_type= InnoDB;
|
|
|
|
# Suppress warnings that might be generated during the test
|
|
disable_query_log;
|
|
connection master;
|
|
call mtr.add_suppression("Timeout waiting for reply of binlog");
|
|
call mtr.add_suppression("Semi-sync master .* waiting for slave reply");
|
|
call mtr.add_suppression("Read semi-sync reply");
|
|
call mtr.add_suppression("Unsafe statement binlogged in statement format since BINLOG_FORMAT = STATEMENT.");
|
|
connection slave;
|
|
call mtr.add_suppression("Master server does not support semi-sync");
|
|
call mtr.add_suppression("Semi-sync slave .* reply");
|
|
enable_query_log;
|
|
|
|
connection master;
|
|
disable_query_log;
|
|
let $value = query_get_value(show variables like 'rpl_semi_sync_master_enabled', Value, 1);
|
|
if (`select '$value' = 'No such row'`)
|
|
{
|
|
set sql_log_bin=0;
|
|
eval INSTALL PLUGIN rpl_semi_sync_master SONAME '$SEMISYNC_MASTER_PLUGIN';
|
|
SET GLOBAL rpl_semi_sync_master_enabled = 1;
|
|
set sql_log_bin=1;
|
|
}
|
|
enable_query_log;
|
|
|
|
connection slave;
|
|
source include/stop_slave.inc;
|
|
|
|
disable_query_log;
|
|
let $value= query_get_value(show variables like 'rpl_semi_sync_slave_enabled', Value, 1);
|
|
if (`select '$value' = 'No such row'`)
|
|
{
|
|
set sql_log_bin=0;
|
|
eval INSTALL PLUGIN rpl_semi_sync_slave SONAME '$SEMISYNC_SLAVE_PLUGIN';
|
|
SET GLOBAL rpl_semi_sync_slave_enabled = 1;
|
|
set sql_log_bin=1;
|
|
}
|
|
enable_query_log;
|
|
|
|
source include/start_slave.inc;
|
|
|
|
connection master;
|
|
SET GLOBAL event_scheduler = ON;
|
|
|
|
replace_result $engine_type ENGINE_TYPE;
|
|
eval CREATE TABLE t1 (i INT NOT NULL AUTO_INCREMENT PRIMARY KEY, f varchar(8)) ENGINE=$engine_type;
|
|
INSERT INTO t1 (f) VALUES ('a'),('a'),('a'),('a'),('a');
|
|
INSERT INTO t1 SELECT i+5, f FROM t1;
|
|
INSERT INTO t1 SELECT i+10, f FROM t1;
|
|
|
|
CREATE EVENT ev1 ON SCHEDULE EVERY 1 SECOND
|
|
DO INSERT INTO t1 VALUES (SLEEP(5),CONCAT('ev1_',CONNECTION_ID()));
|
|
CREATE EVENT ev2 ON SCHEDULE EVERY 1 SECOND
|
|
DO INSERT INTO t1 VALUES (SLEEP(5),CONCAT('ev2_',CONNECTION_ID()));
|
|
|
|
connection slave;
|
|
STOP SLAVE IO_THREAD;
|
|
|
|
connection master;
|
|
let $run = 20;
|
|
while ($run)
|
|
{
|
|
connect (m$run,localhost,root,,);
|
|
connection m$run;
|
|
send;
|
|
eval UPDATE t1 SET f = CONCAT('up_',CONNECTION_ID()) WHERE i = $run;
|
|
connection master;
|
|
dec $run;
|
|
}
|
|
|
|
connection master;
|
|
SET GLOBAL event_scheduler = OFF;
|
|
|
|
let $run = 20;
|
|
while ($run)
|
|
{
|
|
connection m$run;
|
|
reap;
|
|
disconnect m$run;
|
|
dec $run;
|
|
}
|
|
|
|
#
|
|
# Clean up
|
|
#
|
|
connection slave;
|
|
source include/stop_slave.inc;
|
|
|
|
disable_warnings;
|
|
UNINSTALL PLUGIN rpl_semi_sync_slave;
|
|
|
|
connection master;
|
|
UNINSTALL PLUGIN rpl_semi_sync_master;
|
|
enable_warnings;
|
|
|
|
connection slave;
|
|
source include/start_slave.inc;
|
|
|
|
connection master;
|
|
DROP EVENT ev1;
|
|
DROP EVENT ev2;
|
|
DROP TABLE t1;
|
|
sync_slave_with_master;
|