summaryrefslogtreecommitdiff
path: root/mysql-test/t/connect.test
diff options
context:
space:
mode:
authorunknown <knielsen@knielsen-hq.org>2009-03-18 16:46:32 +0100
committerunknown <knielsen@knielsen-hq.org>2009-03-18 16:46:32 +0100
commitce956c8f2d851712a90d304458016221cc74130d (patch)
treeecfb8205b243f3984a3085cb2b9c1d8ba1e5ef26 /mysql-test/t/connect.test
parent2611d3c002df6b37250a996752398c7262d6d8a3 (diff)
downloadmariadb-git-ce956c8f2d851712a90d304458016221cc74130d.tar.gz
Add testing of extra port for pool-of-threads.
The additional test uses up all threads in the pool with SELECT SLEEP(), and tests that this makes normal connections block, but connections on the extra port still work. Also test connection limit on extra port with and without pool-of-threads enabled. Add --connect-timeout option to mysqltest program. Add facility for --extra-port option to ConfigFactory. Fix regexp typo in ConfigFactory.pm
Diffstat (limited to 'mysql-test/t/connect.test')
-rw-r--r--mysql-test/t/connect.test27
1 files changed, 27 insertions, 0 deletions
diff --git a/mysql-test/t/connect.test b/mysql-test/t/connect.test
index 0893bf9ad18..ce352046cba 100644
--- a/mysql-test/t/connect.test
+++ b/mysql-test/t/connect.test
@@ -288,6 +288,33 @@ let $wait_condition =
--echo # -- End of Bug#35074.
--echo
+# Test connections to the extra port.
+
+connect(extracon,127.0.0.1,root,,test,$MASTER_EXTRA_PORT,);
+connection extracon;
+SELECT 'Connection on extra port ok';
+
+connect(extracon2,127.0.0.1,root,,test,$MASTER_EXTRA_PORT,);
+connection extracon2;
+SELECT 'Connection on extra port 2 ok';
+
+--disable_abort_on_error
+--disable_result_log
+--disable_query_log
+connect(extracon3,127.0.0.1,root,,test,$MASTER_EXTRA_PORT,);
+--enable_query_log
+--enable_result_log
+--enable_abort_on_error
+let $error = $mysql_errno;
+if (!$error)
+{
+ --echo # -- Error: managed to establish more than --extra-max-connections + 1 connections
+}
+if ($error)
+{
+ --echo # -- Success: more than --extra-max-connections + 1 normal connections not possible
+}
+
--echo # ------------------------------------------------------------------
--echo # -- End of 5.1 tests
--echo # ------------------------------------------------------------------