Merge branch '2.2' into 2.3
This commit is contained in:
@ -424,6 +424,7 @@ bool mxs_admin_init()
|
||||
void mxs_admin_shutdown()
|
||||
{
|
||||
MHD_stop_daemon(http_daemon);
|
||||
MXS_NOTICE("Stopped MaxScale REST API");
|
||||
}
|
||||
|
||||
bool mxs_admin_https_enabled()
|
||||
|
@ -2255,9 +2255,6 @@ int main(int argc, char** argv)
|
||||
mxb_assert(worker);
|
||||
worker->run();
|
||||
|
||||
/** Stop administrative interface */
|
||||
mxs_admin_shutdown();
|
||||
|
||||
/*< Stop all monitors */
|
||||
monitor_stop_all();
|
||||
|
||||
|
@ -19,6 +19,7 @@
|
||||
|
||||
#include "internal/maxscale.h"
|
||||
#include "internal/service.hh"
|
||||
#include "internal/admin.hh"
|
||||
|
||||
static time_t started;
|
||||
|
||||
@ -50,7 +51,12 @@ int maxscale_shutdown()
|
||||
|
||||
if (n == 0)
|
||||
{
|
||||
mxs::RoutingWorker::shutdown_all();
|
||||
auto w = mxs::RoutingWorker::get(mxs::RoutingWorker::MAIN);
|
||||
w->execute(
|
||||
[]() {
|
||||
mxs_admin_shutdown();
|
||||
mxs::RoutingWorker::shutdown_all();
|
||||
}, nullptr, mxs::RoutingWorker::EXECUTE_QUEUED);
|
||||
}
|
||||
|
||||
return n + 1;
|
||||
|
Reference in New Issue
Block a user