Commit 828cefb3 authored by unknown's avatar unknown

added use of mysql_cluster in mysqld (e.g. for ndb-connectstring)

added warning printout if --ndbcluster switch is given in a "non-cluster" binary

parent 905db498
...@@ -2237,7 +2237,13 @@ extern "C" pthread_handler_decl(handle_shutdown,arg) ...@@ -2237,7 +2237,13 @@ extern "C" pthread_handler_decl(handle_shutdown,arg)
#endif #endif
const char *load_default_groups[]= { "mysqld","server",MYSQL_BASE_VERSION,0,0}; const char *load_default_groups[]= {
#ifdef HAVE_NDBCLUSTER_DB
"mysql_cluster",
#endif
"mysqld","server",MYSQL_BASE_VERSION,0,0};
static const int load_default_groups_sz=
sizeof(load_default_groups)/sizeof(load_default_groups[0]);
bool open_log(MYSQL_LOG *log, const char *hostname, bool open_log(MYSQL_LOG *log, const char *hostname,
const char *opt_name, const char *extension, const char *opt_name, const char *extension,
...@@ -2813,6 +2819,7 @@ int win_main(int argc, char **argv) ...@@ -2813,6 +2819,7 @@ int win_main(int argc, char **argv)
int main(int argc, char **argv) int main(int argc, char **argv)
#endif #endif
{ {
DEBUGGER_OFF; DEBUGGER_OFF;
MY_INIT(argv[0]); // init my_sys library & pthreads MY_INIT(argv[0]); // init my_sys library & pthreads
...@@ -3184,7 +3191,7 @@ int main(int argc, char **argv) ...@@ -3184,7 +3191,7 @@ int main(int argc, char **argv)
and we are now stuck with it. and we are now stuck with it.
*/ */
if (my_strcasecmp(system_charset_info, argv[1],"mysql")) if (my_strcasecmp(system_charset_info, argv[1],"mysql"))
load_default_groups[3]= argv[1]; load_default_groups[load_default_groups_sz-2]= argv[1];
start_mode= 1; start_mode= 1;
Service.Init(argv[1], mysql_service); Service.Init(argv[1], mysql_service);
return 0; return 0;
...@@ -3205,7 +3212,7 @@ int main(int argc, char **argv) ...@@ -3205,7 +3212,7 @@ int main(int argc, char **argv)
opt_argv=argv; opt_argv=argv;
start_mode= 1; start_mode= 1;
if (my_strcasecmp(system_charset_info, argv[2],"mysql")) if (my_strcasecmp(system_charset_info, argv[2],"mysql"))
load_default_groups[3]= argv[2]; load_default_groups[load_default_groups_sz-2]= argv[2];
Service.Init(argv[2], mysql_service); Service.Init(argv[2], mysql_service);
return 0; return 0;
} }
...@@ -6109,6 +6116,9 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)), ...@@ -6109,6 +6116,9 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)),
have_ndbcluster= SHOW_OPTION_YES; have_ndbcluster= SHOW_OPTION_YES;
else else
have_ndbcluster= SHOW_OPTION_DISABLED; have_ndbcluster= SHOW_OPTION_DISABLED;
#else
push_warning(current_thd, MYSQL_ERROR::WARN_LEVEL_ERROR,
0,"this binary does not contain ndbcluster storage engine");
#endif #endif
break; break;
case OPT_INNODB: case OPT_INNODB:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment