Failure to load filters is now a configuration error
When a filter module is not found or the instance creation fails, this is considered a fatal error and MaxScale will not start. If a failure occurs when the configuration is being reloaded, the service will not use filters and an error will be logged.
This commit is contained in:
@ -1028,7 +1028,10 @@ process_config_context(CONFIG_CONTEXT *context)
|
||||
|
||||
if (filters && obj->element)
|
||||
{
|
||||
serviceSetFilters(obj->element, filters);
|
||||
if (!serviceSetFilters(obj->element, filters))
|
||||
{
|
||||
error_count++;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!strcmp(type, "listener"))
|
||||
@ -2141,7 +2144,11 @@ process_config_update(CONFIG_CONTEXT *context)
|
||||
}
|
||||
if (filters && obj->element)
|
||||
{
|
||||
serviceSetFilters(obj->element, filters);
|
||||
if (!serviceSetFilters(obj->element, filters))
|
||||
{
|
||||
MXS_ERROR("Failed to set service filters for '%s'. This "
|
||||
"service will not use filters.", obj->object);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!strcmp(type, "listener"))
|
||||
|
||||
Reference in New Issue
Block a user