I use version kafka-0.8.1.1, in this version autorun does not work through java code. I have a properties file as
props.put("zookeeper.connect", "zoo1:2181,zoo2:2181");
props.put("group.id", KAFKA_GROUPID);
props.put("zookeeper.session.timeout.ms", "10000");
props.put("zookeeper.sync.time.ms", "200");
props.put("auto.commit.interval.ms", "1000");
while I start the consumer stream, it connects to the kafka server, between the stream working with the server, the connection to the kafka server is lost in 2 hours. If it reconnects, the Kafka consumer does not receive any message, nor does it throw any stream error.
How can we detect that he lost the connection and automatically connected the consumer stream.
Thanks in advance
kumar source
share