Move server_set_status and server_clear_status to monitor

The operation goes through monitor code so should be in the according file.
This commit is contained in:
Esa Korhonen
2019-04-26 15:08:31 +03:00
parent b0d8535ead
commit a3bb61486d
8 changed files with 71 additions and 72 deletions

View File

@ -794,7 +794,7 @@ HttpResponse cb_set_server(const HttpRequest& request)
if (opt)
{
string errmsg;
if (mxs::server_set_status(server, opt, &errmsg))
if (MonitorManager::set_server_status(server, opt, &errmsg))
{
if (status_is_in_maint(opt) && request.get_option(CN_FORCE) == CN_YES)
{
@ -821,7 +821,7 @@ HttpResponse cb_clear_server(const HttpRequest& request)
if (opt)
{
string errmsg;
if (mxs::server_clear_status(server, opt, &errmsg))
if (MonitorManager::clear_server_status(server, opt, &errmsg))
{
return HttpResponse(MHD_HTTP_NO_CONTENT);
}