MXS-2304 Remove additional module parameter classes

Equivalent functionality is now in the basic config parameter class.
This commit is contained in:
Esa Korhonen
2019-02-14 18:24:39 +02:00
parent bd3d5bb010
commit 9fbaafea91
12 changed files with 77 additions and 273 deletions

View File

@ -799,16 +799,16 @@ static MXS_ROUTER* createInstance(SERVICE* service, MXS_CONFIG_PARAMETER* params
{
// Declared in config.cc and needs to be removed if/when blr is refactored
extern const MXS_MODULE_PARAM config_server_params[];
MXS_CONFIG_PARAMETER* params = nullptr;
MXS_CONFIG_PARAMETER::set_from_list(&params,
{
{"address", "_none_"},
{"port", "3306"},
{"protocol", "mariadbbackend"},
{"authenticator", "MySQLBackendAuth"}
}, config_server_params);
mxs::ParamList p(
{
{"address", "_none_"},
{"port", "3306"},
{"protocol", "mariadbbackend"},
{"authenticator", "MySQLBackendAuth"}
}, config_server_params);
Server* server = Server::server_alloc("binlog_router_master_host", p.params());
Server* server = Server::server_alloc("binlog_router_master_host", params);
if (server == NULL)
{

View File

@ -138,15 +138,16 @@ int main(int argc, char** argv)
// Declared in config.cc and needs to be removed if/when blr is refactored
extern const MXS_MODULE_PARAM config_server_params[];
mxs::ParamList p(
{
{"address", "_none_"},
{"port", "3306"},
{"protocol", "MySQLBackend"},
{"authenticator", "MySQLBackendAuth"}
}, config_server_params);
MXS_CONFIG_PARAMETER* params = nullptr;
MXS_CONFIG_PARAMETER::set_from_list(&params,
{
{"address", "_none_"},
{"port", "3306"},
{"protocol", "MySQLBackend"},
{"authenticator", "MySQLBackendAuth"}
}, config_server_params);
Server* server = Server::server_alloc("binlog_router_master_host", p.params());
Server* server = Server::server_alloc("binlog_router_master_host", params);
if (server == NULL)
{
printf("Failed to allocate 'server' object\n");