# Increased Kafka Lag due to load balancing

**URL:** <https://discuss.elastic.co/t/increased-kafka-lag-due-to-load-balancing/56041>\
**Category:** Logstash\
**Created:** [July 20, 2016, 11:51pm UTC](https://discuss.elastic.co/t/increased-kafka-lag-due-to-load-balancing/56041 "2016-07-20T23:51:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![stecino](https://avatars.discourse-cdn.com/v4/letter/s/ea666f/32.png) [@stecino](https://discuss.elastic.co/u/stecino)\
**Post date:** [July 20, 2016, 11:51pm UTC](https://discuss.elastic.co/t/increased-kafka-lag-due-to-load-balancing/56041/1 "2016-07-20T23:51:33Z")

</div>

Hello,

I am running logstash 2.2.2 and I recently upgraded kafka input/output 3.x plugin to support consumer offset storage to Kafka 0.9  
As a result, I am connecting to brokers as oppose to Zookeepers. But what I have noticed, since this change, the load balancing is broken. As not all consumers are being assigned to topic partitions resulting in kafka lag increase. Before the upgrade i didn't have this issue as zookeepers where handling the loadbalancing

---

<div class="post-metadata">

**Author:** ![Joe\_Lawson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/joe_lawson/32/3390_2.png) [@Joe\_Lawson](https://discuss.elastic.co/u/Joe_Lawson)\
**Post date:** [August 3, 2016, 6:11pm UTC](https://discuss.elastic.co/t/increased-kafka-lag-due-to-load-balancing/56041/2 "2016-08-03T18:11:54Z")

</div>

I haven't run this setup yet so I don't have much good advice other than you might want to check the Kafka user mailing lists [http://grokbase.com/g/kafka/users](http://grokbase.com/g/kafka/users)

Are all topics being assigned to a consumer or are some being left out? I'm trying to understand if the problem is that the topics aren't being distributed evenly or not at all.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 4:45am UTC](https://discuss.elastic.co/t/increased-kafka-lag-due-to-load-balancing/56041/3 "2017-07-06T04:45:01Z")

</div>

Closed on July 6, 2017, 4:45am UTC


