MXS-1915 Move Monitors on top of mxs::Worker

Monitors are now workers, so the path for making all interaction
between MaxScale proper and the monitors message based is now
open.
This commit is contained in:
Johan Wikman
2018-06-21 15:11:09 +03:00
parent 8ea7d8898a
commit 1eddb29d91
3 changed files with 101 additions and 97 deletions

View File

@ -1927,6 +1927,20 @@ int main(int argc, char **argv)
MXS_NOTICE("Module directory: %s", get_libdir());
MXS_NOTICE("Service cache: %s", get_cachedir());
if (!MessageQueue::init())
{
MXS_ERROR("Failed to initialize message queue.");
rc = MAXSCALE_INTERNALERROR;
goto return_main;
}
if (!Worker::init())
{
MXS_ERROR("Failed to initialize workers.");
rc = MAXSCALE_INTERNALERROR;
goto return_main;
}
if (!config_load(cnf_file_path))
{
const char* fprerr =
@ -2013,20 +2027,6 @@ int main(int argc, char **argv)
goto return_main;
}
if (!MessageQueue::init())
{
MXS_ERROR("Failed to initialize message queue.");
rc = MAXSCALE_INTERNALERROR;
goto return_main;
}
if (!Worker::init())
{
MXS_ERROR("Failed to initialize workers.");
rc = MAXSCALE_INTERNALERROR;
goto return_main;
}
if (!RoutingWorker::init())
{
MXS_ERROR("Failed to initialize routing workers.");