Commit eb52caf5 authored by Geoff Simmons's avatar Geoff Simmons

MQ plugin for Kafka: change the config param name for zookeeper connection

timeouts to the name used by Apache Kafka
parent 778656ba
...@@ -154,10 +154,10 @@ Parameter Description ...@@ -154,10 +154,10 @@ Parameter Description
``metadata.broker.list`` MUST be set, as ``metadata.broker.list`` MUST be set, as
described above. described above.
----------------------------------- -------------------------------------------- ----------------------------------- --------------------------------------------
``zookeeper.timeout`` Timeout in milliseconds for connections to ``zookeeper.connection.timeout.ms`` Timeout for connections to ZooKeeper
ZooKeeper servers. If 0, then a connection servers. If 0, then a connection attempt
attempt fails immediately if the servers fails immediately if the servers cannot be
cannot be reached. (optional, default 0) reached. (optional, default 0)
----------------------------------- -------------------------------------------- ----------------------------------- --------------------------------------------
``zookeeper.log`` Path of a log file for the ZooKeeper client ``zookeeper.log`` Path of a log file for the ZooKeeper client
(optional) (optional)
......
...@@ -89,8 +89,7 @@ CONF_Add(const char *lval, const char *rval) ...@@ -89,8 +89,7 @@ CONF_Add(const char *lval, const char *rval)
strncpy(zookeeper, rval, LINE_MAX); strncpy(zookeeper, rval, LINE_MAX);
return(0); return(0);
} }
/* XXX: "zookeeper.connection.timeout.ms", to match Kafka config */ if (strcmp(lval, "zookeeper.connection.timeout.ms") == 0) {
if (strcmp(lval, "zookeeper.timeout") == 0) {
if ((err = conf_getUnsignedInt(rval, &zoo_timeout)) != 0) if ((err = conf_getUnsignedInt(rval, &zoo_timeout)) != 0)
return(err); return(err);
return(0); return(0);
......
# test config for Kafka MQ plugin # test config for Kafka MQ plugin
mq.log = kafka.log mq.log = kafka.log
zookeeper.connect = localhost:2181 zookeeper.connect = localhost:2181
zookeeper.timeout = 10000 zookeeper.connection.timeout.ms = 10000
zookeeper.log = zoo.log zookeeper.log = zoo.log
topic = libtrackrdr_kafka_test topic = libtrackrdr_kafka_test
mq.debug = true mq.debug = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment