3507 chuck.bell@stripped 2011-10-18 [merge]
Merge with BUG#12968815, BUG#12968567 for mysql_plugin client.
modified:
client/mysql_plugin.c
mysql-test/r/mysql_plugin.result
mysql-test/t/mysql_plugin.test
3506 Sneha MOdi 2011-10-18
These tests were failing sporadically on push build.
They have been fixed.
The variable metadata_table_reference_number showed different outputs for different
runs.
modified:
mysql-test/suite/sys_vars/r/innodb_monitor_disable_basic.result
mysql-test/suite/sys_vars/r/innodb_monitor_enable_basic.result
mysql-test/suite/sys_vars/r/innodb_monitor_reset_all_basic.result
mysql-test/suite/sys_vars/r/innodb_monitor_reset_basic.result
mysql-test/suite/sys_vars/t/innodb_monitor_disable_basic.test
mysql-test/suite/sys_vars/t/innodb_monitor_enable_basic.test
mysql-test/suite/sys_vars/t/innodb_monitor_reset_all_basic.test
mysql-test/suite/sys_vars/t/innodb_monitor_reset_basic.test
=== modified file 'client/mysql_plugin.c'
--- a/client/mysql_plugin.c 2011-09-23 10:55:10 +0000
+++ b/client/mysql_plugin.c 2011-10-18 12:33:26 +0000
@@ -1081,7 +1081,7 @@ static int build_bootstrap_file(char *op
else
{
fprintf(file,
- "DELETE FROM mysql.plugin WHERE name = '%s';", plugin_data.name);
+ "DELETE FROM mysql.plugin WHERE dl = '%s';", plugin_data.so_name);
if (opt_verbose)
{
printf("# Disabling %s...\n", plugin_data.name);
@@ -1160,7 +1160,6 @@ static int bootstrap_server(char *server
{
char bootstrap_cmd[FN_REFLEN];
int error= 0;
- int ret= 0;
#ifdef __WIN__
char *format_str= 0;
@@ -1196,7 +1195,7 @@ static int bootstrap_server(char *server
if (error)
fprintf(stderr,
"ERROR: Unexpected result from bootstrap. Error code: %d.\n",
- ret);
+ error);
return error;
}
=== modified file 'mysql-test/r/mysql_plugin.result'
--- a/mysql-test/r/mysql_plugin.result 2011-09-23 10:55:10 +0000
+++ b/mysql-test/r/mysql_plugin.result 2011-10-18 12:33:26 +0000
@@ -1,24 +1,34 @@
#
# Ensure the plugin isn't loaded.
#
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
name dl
#
# Enable the plugin...
#
#
+# Simulate loading a plugin libary with multiple entry points.
+# This will test the DISABLE to ensure all rows are removed.
+#
+INSERT INTO mysql.plugin VALUES ('wicky', 'libdaemon_example.so');
+INSERT INTO mysql.plugin VALUES ('wacky', 'libdaemon_example.so');
+INSERT INTO mysql.plugin VALUES ('wonky', 'libdaemon_example.so');
+#
# Ensure the plugin is now loaded.
#
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
name dl
daemon_example libdaemon_example.so
+wacky libdaemon_example.so
+wicky libdaemon_example.so
+wonky libdaemon_example.so
#
# Disable the plugin...
#
#
# Ensure the plugin isn't loaded.
#
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
name dl
#
# Attempt to load non-existant plugin
=== modified file 'mysql-test/t/mysql_plugin.test'
--- a/mysql-test/t/mysql_plugin.test 2011-09-26 09:19:12 +0000
+++ b/mysql-test/t/mysql_plugin.test 2011-10-18 12:33:26 +0000
@@ -105,7 +105,7 @@ let $MYSQL_PLUGIN_CMD= $MYSQL_PLUGIN --d
--echo #
--echo # Ensure the plugin isn't loaded.
--echo #
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
--echo #
--echo # Enable the plugin...
@@ -139,10 +139,18 @@ EOF
--source include/wait_until_connected_again.inc
--echo #
+--echo # Simulate loading a plugin libary with multiple entry points.
+--echo # This will test the DISABLE to ensure all rows are removed.
+--echo #
+eval INSERT INTO mysql.plugin VALUES ('wicky', '$DAEMONEXAMPLE');
+eval INSERT INTO mysql.plugin VALUES ('wacky', '$DAEMONEXAMPLE');
+eval INSERT INTO mysql.plugin VALUES ('wonky', '$DAEMONEXAMPLE');
+
+--echo #
--echo # Ensure the plugin is now loaded.
--echo #
--replace_regex /\.dll/.so/
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
--echo #
--echo # Disable the plugin...
@@ -173,7 +181,7 @@ EOF
--echo #
--echo # Ensure the plugin isn't loaded.
--echo #
-SELECT * FROM mysql.plugin WHERE name = 'daemon_example' ORDER BY name;
+SELECT * FROM mysql.plugin WHERE dl like 'libdaemon%' ORDER BY name;
#
# Stop the server for error conditions
No bundle (reason: useless for push emails).
| Thread |
|---|
| • bzr push into mysql-trunk branch (chuck.bell:3506 to 3507) Bug#12968567Bug#12968815 | chuck.bell | 18 Oct |