MXS-1446: Move failover parameters into mysqlmon

The `failover` and `failover_timeout` parameters are now declared as a
part of the mysqlmon module. Changed the implementation of the failover
function so that the dependencies on the monitor struct can be removed or
moved into parameters.
This commit is contained in:
Markus Mäkelä
2017-09-28 08:15:28 +03:00
parent ef115208e6
commit d4fd34cecd
7 changed files with 44 additions and 120 deletions

View File

@ -522,25 +522,6 @@ bool runtime_alter_monitor(MXS_MONITOR *monitor, const char *key, const char *va
monitorSetScriptTimeout(monitor, ival);
}
}
else if (strcmp(key, CN_FAILOVER_TIMEOUT) == 0)
{
long ival = get_positive_int(value);
if (ival)
{
valid = true;
monitorSetFailoverTimeout(monitor, ival);
}
}
else if (strcmp(key, CN_FAILOVER) == 0)
{
int val = config_truth_value(value);
if (val != -1)
{
valid = true;
monitorSetFailover(monitor, val);
}
}
else
{
/** We're modifying module specific parameters and we need to stop the monitor */