MXS-1220: Add PUT support for services

Service parameters can now be altered with a PUT request to the REST
API. This allows general level parameters to be altered.

Module specific parameters need to be altered with a different mechanism,
namely the module command system. This requires that a generic way to call
a function needs to be devised.
This commit is contained in:
Markus Mäkelä
2017-04-25 21:48:30 +03:00
parent d282b14b36
commit d248c7e081
3 changed files with 95 additions and 0 deletions

View File

@ -228,4 +228,14 @@ MXS_MONITOR* runtime_create_monitor_from_json(json_t* json);
*/
bool runtime_alter_monitor_from_json(MXS_MONITOR* monitor, json_t* new_json);
/**
* @brief Alter a service using JSON
*
* @param service Service to alter
* @param new_json JSON definition of the updated service
*
* @return True if the service was successfully modified to represent @c new_json
*/
bool runtime_alter_service_from_json(SERVICE* service, json_t* new_json);
MXS_END_DECLS