Fix avrorouter and cluster usage

The servers defined by `cluster` wouldn't get used.
This commit is contained in:
Markus Mäkelä
2019-06-26 10:05:21 +03:00
parent 59e7b2b09d
commit 01822490ca
3 changed files with 3 additions and 2 deletions

View File

@ -133,7 +133,7 @@ Avro::Avro(SERVICE* service, MXS_CONFIG_PARAMETER* params, SERVICE* source, SRow
, handler(service, handler, params->get_compiled_regex("match", 0, NULL).release(),
params->get_compiled_regex("exclude", 0, NULL).release())
{
if (params->contains(CN_SERVERS))
if (params->contains(CN_SERVERS) || params->contains(CN_CLUSTER))
{
MXS_NOTICE("Replicating directly from a master server");
cdc::Config cnf;

View File

@ -68,7 +68,7 @@ MXS_ROUTER* createInstance(SERVICE* service, MXS_CONFIG_PARAMETER* params)
Avro* router = Avro::create(service, handler);
if (router && !params->contains(CN_SERVERS))
if (router && !params->contains(CN_SERVERS) && !params->contains(CN_CLUSTER))
{
conversion_task_ctl(router, true);
}