From a6182d48bf3a633323c5865d19ecc20c8a3db6fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=A4kel=C3=A4?= Date: Wed, 27 Jun 2018 10:49:32 +0300 Subject: [PATCH] MXS-1643: Only test existence of extra events mxs1643_extra_events Don't test failover functionality when it is not needed. The bug is only about the extra events that appear when a master is demoted and a slave is promoted. --- .../cnf/maxscale.cnf.template.mxs1643_extra_events | 10 ---------- maxscale-system-test/mxs1643_extra_events.cpp | 11 +---------- 2 files changed, 1 insertion(+), 20 deletions(-) diff --git a/maxscale-system-test/cnf/maxscale.cnf.template.mxs1643_extra_events b/maxscale-system-test/cnf/maxscale.cnf.template.mxs1643_extra_events index 99754a00a..70201df8b 100644 --- a/maxscale-system-test/cnf/maxscale.cnf.template.mxs1643_extra_events +++ b/maxscale-system-test/cnf/maxscale.cnf.template.mxs1643_extra_events @@ -8,16 +8,6 @@ servers= server1,server2,server3,server4 user=maxskysql passwd= skysql monitor_interval=1000 -detect_standalone_master=true -failcount=1 -allow_cluster_recovery=true -replication_user=repl -replication_password=repl -backend_connect_timeout=3 -backend_read_timeout=3 -backend_write_timeout=3 -auto_failover=true -auto_rejoin=true [RW Split Router] type=service diff --git a/maxscale-system-test/mxs1643_extra_events.cpp b/maxscale-system-test/mxs1643_extra_events.cpp index 628172653..09ebe40fc 100644 --- a/maxscale-system-test/mxs1643_extra_events.cpp +++ b/maxscale-system-test/mxs1643_extra_events.cpp @@ -7,7 +7,6 @@ int main(int argc, char** argv) { - Mariadb_nodes::require_gtid(true); TestConnections test(argc, argv); // Check that master gets the slave status when set into read-only mode @@ -18,22 +17,14 @@ int main(int argc, char** argv) test.tprintf("Check that the current master now has the slave label"); test.check_log_err(0, "[Master, Running] -> [Running]", false); test.check_log_err(0, "[Master, Running] -> [Slave, Running]", true); - execute_query(test.repl->nodes[0], "SET GLOBAL read_only=OFF"); - test.maxscales->wait_for_monitor(); test.maxscales->ssh_node_f(0, true, "truncate -s 0 /var/log/maxscale/maxscale.log"); // Check that the Master and Slave status aren't both set - test.tprintf("Block master and wait for monitor to detect it."); - test.repl->block_node(0); + execute_query(test.repl->nodes[0], "SET GLOBAL read_only=OFF"); test.maxscales->wait_for_monitor(); test.tprintf("Check that the new master doesn't have both slave and master labels"); test.check_log_err(0, "[Slave, Running] -> [Master, Slave, Running]", false); test.check_log_err(0, "[Slave, Running] -> [Master, Running]", true); - test.repl->unblock_node(0); - - test.tprintf("Cleanup"); - test.repl->execute_query_all_nodes( "STOP ALL SLAVES; RESET SLAVE ALL;"); - test.repl->fix_replication(); return test.global_result; }