mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
fixed message in post-commit trigger
added debugging options to master to behave sporadically, and a test case to make sure the slave can deal with it BitKeeper/triggers/post-commit: fixed message sql/mysqld.cc: added debugging options to force the master to occasionally break replication sql/slave.cc: cosmetic change to improve readability sql/sql_repl.cc: support for --sporadic-binlog-dump-fail and --max-binlog-dump-events sql/sql_repl.h: support for --sporadic-binlog-dump-fail and --max-binlog-dump-events
This commit is contained in:
@ -20,6 +20,7 @@
|
||||
#include <my_dir.h>
|
||||
#include "sql_acl.h"
|
||||
#include "slave.h"
|
||||
#include "sql_repl.h"
|
||||
#include "stacktrace.h"
|
||||
#ifdef HAVE_BERKELEY_DB
|
||||
#include "ha_berkeley.h"
|
||||
@ -2461,7 +2462,8 @@ enum options {
|
||||
OPT_TEMP_POOL, OPT_TX_ISOLATION,
|
||||
OPT_GEMINI_FLUSH_LOG, OPT_GEMINI_RECOVER,
|
||||
OPT_GEMINI_UNBUFFERED_IO, OPT_SKIP_SAFEMALLOC,
|
||||
OPT_SKIP_STACK_TRACE, OPT_SKIP_SYMLINKS
|
||||
OPT_SKIP_STACK_TRACE, OPT_SKIP_SYMLINKS,
|
||||
OPT_MAX_BINLOG_DUMP_EVENTS, OPT_SPORADIC_BINLOG_DUMP_FAIL
|
||||
};
|
||||
|
||||
static struct option long_options[] = {
|
||||
@ -2545,6 +2547,10 @@ static struct option long_options[] = {
|
||||
(int) OPT_DISCONNECT_SLAVE_EVENT_COUNT},
|
||||
{"abort-slave-event-count", required_argument, 0,
|
||||
(int) OPT_ABORT_SLAVE_EVENT_COUNT},
|
||||
{"max-binlog-dump-events", required_argument, 0,
|
||||
(int) OPT_MAX_BINLOG_DUMP_EVENTS},
|
||||
{"sporadic-binlog-dump-fail", no_argument, 0,
|
||||
(int) OPT_SPORADIC_BINLOG_DUMP_FAIL},
|
||||
{"safemalloc-mem-limit", required_argument, 0, (int)
|
||||
OPT_SAFEMALLOC_MEM_LIMIT},
|
||||
{"new", no_argument, 0, 'n'},
|
||||
@ -3301,6 +3307,17 @@ static void get_options(int argc,char **argv)
|
||||
abort_slave_event_count = atoi(optarg);
|
||||
#endif
|
||||
break;
|
||||
case (int)OPT_SPORADIC_BINLOG_DUMP_FAIL:
|
||||
#ifndef DBUG_OFF
|
||||
opt_sporadic_binlog_dump_fail = 1;
|
||||
#endif
|
||||
break;
|
||||
case (int)OPT_MAX_BINLOG_DUMP_EVENTS:
|
||||
#ifndef DBUG_OFF
|
||||
max_binlog_dump_events = atoi(optarg);
|
||||
#endif
|
||||
break;
|
||||
|
||||
case (int) OPT_LOG_SLAVE_UPDATES:
|
||||
opt_log_slave_updates = 1;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user