4072 magnus.blaudd@stripped 2012-11-06 [merge]
Merge
modified:
mysql-test/include/wait_for_ndb_to_binlog.inc
mysql-test/r/ctype_cp932_binlog_stm.result
mysql-test/t/ctype_cp932_binlog_stm.test
storage/ndb/CMakeLists.txt
storage/ndb/compile-cluster
4071 magnus.blaudd@stripped 2012-11-06 [merge]
Merge 7.1 -> 7.2
modified:
mysql-test/suite/ndb/r/ndb_basic.result
mysql-test/suite/ndb/r/ndb_index.result
mysql-test/suite/ndb/t/ndb_index.test
sql/ha_ndbcluster.cc
storage/ndb/src/ndbapi/ndberror.c
=== modified file 'mysql-test/include/wait_for_ndb_to_binlog.inc'
--- a/mysql-test/include/wait_for_ndb_to_binlog.inc 2012-03-30 06:33:44 +0000
+++ b/mysql-test/include/wait_for_ndb_to_binlog.inc 2012-11-02 17:22:45 +0000
@@ -1,13 +1,11 @@
# ==== Purpose ====
#
-# Several test primitives from mysql-test/extra/rpl_tests
-# shared for test cases for MyISAM, InnoDB, NDB and other
-# engines. But for NDB all events will be added by NDB
-# injector and now there are no way to detect the state of
-# NDB injector therefore this primitive waits 5 sec
-# if engine type is NDB.
-# In future that should be fixed by waiting of proper
-# state of NDB injector.
+# Several test primitives from mysql-test/extra/rpl_tests
+# are shared for test cases for MyISAM, InnoDB, NDB and
+# other engines.
+# For NDB engine all events will be added by NDB injector
+# so tests only can continue after injector is ready,
+# this test waits for proper injector thread state.
#
# ==== Usage ====
#
@@ -17,25 +15,12 @@
# ==== Parameters =====
#
# $engine_type
-# Type of engine. If type is NDB then it waits $wait_time sec
-#
-# $wait_time
-# Test will wait $wait_time seconds
-
-let $_wait_time= 5;
-
-if ($wait_time) {
- let $_wait_time= $wait_time;
-}
+# Type of engine. If type is NDB then it waits for injector
+# thread proper state.
if (`SELECT UPPER(LEFT('$engine_type',3)) = 'NDB'`) {
- while (!$_wait_time) {
- let $_wait_time_internal= 10;
- while (!$_wait_time_internal) {
- sleep 0.1;
- dec $_wait_time_internal;
- }
- dec $_wait_time;
- }
+ let $show_statement= SHOW PROCESSLIST;
+ let $field= State;
+ let $condition= = 'Waiting for event from ndbcluster';
+ source include/wait_show_condition.inc;
}
-
=== modified file 'mysql-test/r/ctype_cp932_binlog_stm.result'
--- a/mysql-test/r/ctype_cp932_binlog_stm.result 2012-09-12 15:11:40 +0000
+++ b/mysql-test/r/ctype_cp932_binlog_stm.result 2012-11-02 13:38:51 +0000
@@ -49,7 +49,7 @@ master-bin.000001 # Query # # COMMIT
master-bin.000001 # Query # # use `test`; DROP PROCEDURE bug18293
master-bin.000001 # Query # # use `test`; DROP TABLE `t4` /* generated by server */
End of 5.0 tests
-SHOW BINLOG EVENTS FROM 495;
+SHOW BINLOG EVENTS FROM 490;
ERROR HY000: Error when executing command SHOW BINLOG EVENTS: Wrong offset or I/O error
Bug#44352 UPPER/LOWER function doesn't work correctly on cp932 and sjis environment.
CREATE TABLE t1 (a varchar(16)) character set cp932;
=== modified file 'mysql-test/t/ctype_cp932_binlog_stm.test'
--- a/mysql-test/t/ctype_cp932_binlog_stm.test 2012-09-12 15:11:40 +0000
+++ b/mysql-test/t/ctype_cp932_binlog_stm.test 2012-11-02 13:38:51 +0000
@@ -36,7 +36,7 @@ delimiter ;|
#
# #28436: Incorrect position in SHOW BINLOG EVENTS causes server coredump
--error 1220
-SHOW BINLOG EVENTS FROM 495;
+SHOW BINLOG EVENTS FROM 490;
--echo Bug#44352 UPPER/LOWER function doesn't work correctly on cp932 and sjis environment.
CREATE TABLE t1 (a varchar(16)) character set cp932;
=== modified file 'storage/ndb/CMakeLists.txt'
--- a/storage/ndb/CMakeLists.txt 2012-10-17 16:16:17 +0000
+++ b/storage/ndb/CMakeLists.txt 2012-11-06 12:47:36 +0000
@@ -18,7 +18,7 @@ SET(CMAKE_MODULE_PATH ${CMAKE_MODULE_PAT
${CMAKE_SOURCE_DIR}/storage/ndb/cmake)
MESSAGE(STATUS "Using cmake version ${CMAKE_VERSION}")
-
+
# Check if this is MySQL Cluster build i.e the MySQL Server
# version string ends in -ndb-Y.Y.Y[-status]
MACRO(NDB_CHECK_MYSQL_CLUSTER version_string)
@@ -26,9 +26,7 @@ MACRO(NDB_CHECK_MYSQL_CLUSTER version_st
IF(${version_string} MATCHES "(.*)-ndb-(.*)")
SET(mysql_version ${CMAKE_MATCH_1})
SET(cluster_version ${CMAKE_MATCH_2})
-
- MESSAGE(STATUS "This is MySQL Cluster ${cluster_version}")
-
+
# Sanity check that the mysql_version matches precalcuated
# values from higher level scripts
IF(NOT ${mysql_version} EQUAL "${MYSQL_NO_DASH_VERSION}")
@@ -42,6 +40,7 @@ MACRO(NDB_CHECK_MYSQL_CLUSTER version_st
SET(MYSQL_CLUSTER_VERSION_BUILD ${CMAKE_MATCH_3})
ENDIF()
+ MESSAGE(STATUS "This is MySQL Cluster ${cluster_version}")
# Finally set MYSQL_CLUSTER_VERSION to be used as an indicator
# that this is a MySQL Cluster build, yay!
SET(MYSQL_CLUSTER_VERSION ${cluster_version})
@@ -106,10 +105,15 @@ IF(NOT MYSQL_CLUSTER_VERSION)
ADD_DEFINITIONS(-DNDB_WITHOUT_JOIN_PUSHDOWN)
ENDIF()
-# NDB is DEFAULT plugin in MySQL Cluster
SET(is_default_plugin "")
-IF(MYSQL_CLUSTER_VERSION)
- SET(is_default_plugin "DEFAULT")
+OPTION(WITH_NDB_DEFAULT_PLUGIN_DETECT
+ "Autodetect MySQL Cluster version and set ndbcluster as DEFAULT plugin" ON)
+MARK_AS_ADVANCED(WITH_NDB_DEFAULT_PLUGIN_DETECT)
+IF(WITH_NDB_DEFAULT_PLUGIN_DETECT)
+ IF(MYSQL_CLUSTER_VERSION)
+ # ndbcluster is DEFAULT plugin in MySQL Cluster
+ SET(is_default_plugin "DEFAULT")
+ ENDIF()
ENDIF()
MYSQL_ADD_PLUGIN(ndbcluster ${NDBCLUSTER_SOURCES} STORAGE_ENGINE
=== modified file 'storage/ndb/compile-cluster'
--- a/storage/ndb/compile-cluster 2012-04-11 12:23:22 +0000
+++ b/storage/ndb/compile-cluster 2012-11-02 12:55:01 +0000
@@ -34,7 +34,7 @@ my $opt_debug;
my $opt_build_type;
my $opt_build = 1;
my $opt_just_print;
-
+my $opt_vanilla;
Getopt::Long::Configure("pass_through");
GetOptions(
@@ -45,6 +45,7 @@ GetOptions(
'build!' => \$opt_build,
'c|just-configure' => sub { $opt_build = 0; },
'n|just-print' => \$opt_just_print,
+ 'vanilla' => \$opt_vanilla,
) or exit(1);
# Find source root directory, assume this script is
@@ -84,18 +85,30 @@ my $cmake_version_id;
my @args;
- # Hardcoded options controlling how to build MySQL Server
- push(@args, "-DWITH_SSL=bundled"); # Consistent error messages
-
if ($opt_debug)
{
push(@args, "-DWITH_DEBUG=1");
push(@args, "-DMYSQL_MAINTAINER_MODE=0");
}
- # Hardcoded options controlling how to build NDB
- push(@args, "-DWITH_PLUGIN_NDBCLUSTER=1");
- push(@args, "-DWITH_NDB_TEST=1");
+ if ($opt_vanilla)
+ {
+ # Use default options for building
+ print("compile-cluster: vanilla build requested, no sugar\n");
+
+ # Turn off automatic detection of WITH_NDBCLUSTER
+ # in MySQL Cluster version(i.e when version string ends in -ndb-Y.Y.Y)
+ push(@args, "-DWITH_NDB_DEFAULT_PLUGIN_DETECT=0");
+ }
+ else
+ {
+ # Hardcoded options controlling how to build MySQL Server
+ push(@args, "-DWITH_SSL=bundled"); # Consistent error messages
+
+ # Hardcoded options controlling how to build NDB
+ push(@args, "-DWITH_PLUGIN_NDBCLUSTER=1");
+ push(@args, "-DWITH_NDB_TEST=1");
+ }
# The cmake generator to use
if ($opt_build_type)
No bundle (reason: useless for push emails).
| Thread |
|---|
| • bzr push into mysql-5.5-cluster-7.2 branch (magnus.blaudd:4071 to 4072) | magnus.blaudd | 16 Nov |