Use correct service name and router module name
Both the base class and derived class had the fields, but the derived fields were left blank.
This commit is contained in:
@ -115,8 +115,6 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
FilterList m_filters; /**< Ordered list of filters */
|
FilterList m_filters; /**< Ordered list of filters */
|
||||||
std::string m_name; /**< Name of the service */
|
|
||||||
std::string m_router_name; /**< Router module */
|
|
||||||
std::string m_user; /**< Username */
|
std::string m_user; /**< Username */
|
||||||
std::string m_password; /**< Password */
|
std::string m_password; /**< Password */
|
||||||
std::string m_weightby; /**< Weighting parameter name */
|
std::string m_weightby; /**< Weighting parameter name */
|
||||||
|
@ -1086,7 +1086,7 @@ bool Service::refresh_users()
|
|||||||
{
|
{
|
||||||
MXS_WARNING("[%s] Refresh rate limit (once every %ld seconds) exceeded for "
|
MXS_WARNING("[%s] Refresh rate limit (once every %ld seconds) exceeded for "
|
||||||
"load of users' table.",
|
"load of users' table.",
|
||||||
m_name.c_str(),
|
name(),
|
||||||
config->users_refresh_time);
|
config->users_refresh_time);
|
||||||
m_rate_limits[self].warned = true;
|
m_rate_limits[self].warned = true;
|
||||||
}
|
}
|
||||||
@ -1105,7 +1105,7 @@ bool Service::refresh_users()
|
|||||||
case MXS_AUTH_LOADUSERS_FATAL:
|
case MXS_AUTH_LOADUSERS_FATAL:
|
||||||
MXS_ERROR("[%s] Fatal error when loading users for listener '%s',"
|
MXS_ERROR("[%s] Fatal error when loading users for listener '%s',"
|
||||||
" authentication will not work.",
|
" authentication will not work.",
|
||||||
m_name.c_str(),
|
name(),
|
||||||
listener->name());
|
listener->name());
|
||||||
ret = false;
|
ret = false;
|
||||||
break;
|
break;
|
||||||
@ -1113,7 +1113,7 @@ bool Service::refresh_users()
|
|||||||
case MXS_AUTH_LOADUSERS_ERROR:
|
case MXS_AUTH_LOADUSERS_ERROR:
|
||||||
MXS_WARNING("[%s] Failed to load users for listener '%s', authentication"
|
MXS_WARNING("[%s] Failed to load users for listener '%s', authentication"
|
||||||
" might not work.",
|
" might not work.",
|
||||||
m_name.c_str(),
|
name(),
|
||||||
listener->name());
|
listener->name());
|
||||||
ret = false;
|
ret = false;
|
||||||
break;
|
break;
|
||||||
@ -1416,7 +1416,7 @@ bool Service::dump_config(const char* filename) const
|
|||||||
{
|
{
|
||||||
MXS_ERROR("Failed to open file '%s' when serializing service '%s': %d, %s",
|
MXS_ERROR("Failed to open file '%s' when serializing service '%s': %d, %s",
|
||||||
filename,
|
filename,
|
||||||
m_name.c_str(),
|
name(),
|
||||||
errno,
|
errno,
|
||||||
mxs_strerror(errno));
|
mxs_strerror(errno));
|
||||||
return false;
|
return false;
|
||||||
@ -1425,7 +1425,7 @@ bool Service::dump_config(const char* filename) const
|
|||||||
/**
|
/**
|
||||||
* TODO: Check for return values on all of the dprintf calls
|
* TODO: Check for return values on all of the dprintf calls
|
||||||
*/
|
*/
|
||||||
dprintf(file, "[%s]\n", m_name.c_str());
|
dprintf(file, "[%s]\n", name());
|
||||||
dprintf(file, "%s=service\n", CN_TYPE);
|
dprintf(file, "%s=service\n", CN_TYPE);
|
||||||
|
|
||||||
if (!m_filters.empty())
|
if (!m_filters.empty())
|
||||||
@ -1458,7 +1458,7 @@ bool Service::dump_config(const char* filename) const
|
|||||||
dprintf(file, "\n");
|
dprintf(file, "\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
const MXS_MODULE* mod = get_module(m_router_name.c_str(), NULL);
|
const MXS_MODULE* mod = get_module(router_name(), NULL);
|
||||||
mxb_assert(mod);
|
mxb_assert(mod);
|
||||||
|
|
||||||
dump_param_list(file,
|
dump_param_list(file,
|
||||||
|
Reference in New Issue
Block a user