MXS-2313: Add server ranks

The servers now accept a rank parameter that tells which servers to
prioritize.
This commit is contained in:
Markus Mäkelä
2019-03-08 10:55:00 +02:00
parent 9e9cd0c596
commit 0693514047
5 changed files with 34 additions and 0 deletions

View File

@ -619,6 +619,13 @@ bool runtime_alter_server(Server* server, const char* key, const char* value)
server->set_persistmaxtime(atoi(value));
}
}
if (strcmp(key, CN_RANK) == 0)
{
if (is_valid_integer(value))
{
server->set_rank(atoi(value));
}
}
else
{
/**