# More consumer threads than the number specified in the input plugin

**URL:** <https://discuss.elastic.co/t/more-consumer-threads-than-the-number-specified-in-the-input-plugin/190241>\
**Category:** Logstash\
**Created:** [July 12, 2019, 1:05pm UTC](https://discuss.elastic.co/t/more-consumer-threads-than-the-number-specified-in-the-input-plugin/190241 "2019-07-12T13:05:32Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![amitavmohanty01](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/amitavmohanty01/32/58017_2.png) [@amitavmohanty01](https://discuss.elastic.co/u/amitavmohanty01)\
**Post date:** [July 12, 2019, 1:05pm UTC](https://discuss.elastic.co/t/more-consumer-threads-than-the-number-specified-in-the-input-plugin/190241/1 "2019-07-12T13:05:32Z")

</div>

I have 6 logstash nodes. Each node has a pipeline with the following input section.

```
input {
  kafka {
    bootstrap_servers => "<list of kafka brokers>"
    client_id => "unique_client_id"
    group_id => "common_group_id_for_logstash"
    topics => [log_topic]
    tags => ["log"]
    security_protocol => "SSL"
    consumer_threads => 2
  }
}

```

The number of partitions is 12. So, each node should have 2 threads in the group and all threads should be listening to unique partitions. However, when I checked the consumer group in Kafka, I found the following distribution.

logstash01 - 4 threads  
logstash02 - 4 threads  
logstash06 - 4 threads

Why are more threads than 2 being used from the above hosts? Why are other hosts not getting any partitions allocated?

---

<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:** [August 9, 2019, 1:05pm UTC](https://discuss.elastic.co/t/more-consumer-threads-than-the-number-specified-in-the-input-plugin/190241/2 "2019-08-09T13:05:34Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
