From 514b5f7856fe6ba13756038b7280fd491a1e41da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=A4kel=C3=A4?= Date: Fri, 9 Nov 2018 09:26:42 +0200 Subject: [PATCH] Fix mxs359_read_only Due to the changes in the monitor, an explicit failcount=1 and extra waits are required to make sure the master actually changes. --- maxscale-system-test/cnf/maxscale.cnf.template.mxs359_read_only | 1 + maxscale-system-test/mxs359_read_only.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/maxscale-system-test/cnf/maxscale.cnf.template.mxs359_read_only b/maxscale-system-test/cnf/maxscale.cnf.template.mxs359_read_only index 45249cce3..cc1816d43 100644 --- a/maxscale-system-test/cnf/maxscale.cnf.template.mxs359_read_only +++ b/maxscale-system-test/cnf/maxscale.cnf.template.mxs359_read_only @@ -8,6 +8,7 @@ servers=server1,server2,server3,server4 user=maxskysql password=skysql monitor_interval=1000 +failcount=1 [RW-Split-Router] type=service diff --git a/maxscale-system-test/mxs359_read_only.cpp b/maxscale-system-test/mxs359_read_only.cpp index 34af9a794..7e45da89a 100644 --- a/maxscale-system-test/mxs359_read_only.cpp +++ b/maxscale-system-test/mxs359_read_only.cpp @@ -65,7 +65,7 @@ void test_new_master(TestConnections& test, std::ostream& out) test.try_query(test.maxscales->conn_rwsplit[0], "SELECT * FROM test.t1"); change_master(1, 0); - test.maxscales->wait_for_monitor(); + test.maxscales->wait_for_monitor(2); out << "Both reads and writes after master change should work" << endl; test.try_query(test.maxscales->conn_rwsplit[0], "INSERT INTO test.t1 VALUES (2)");