Hi

Background :

I am using a java based multithreaded kafka consumer.

Two instances of  this consumer are running on 2 different machines i.e.
one consumer process per box, and  belong to same consumer group.

Internally each process has 2 threads each.

Both the consumer processes consume from same topic "rawlogs" which has 4
partitions.

Problem :

As per the documentation of consumer group "each message published to a
topic is delivered to one consumer instance within each subscribing consumer
group" . But is there any mechanism by which a each consumer consumes from
disjoint set of partitions too ? or each message from whichever partition
it is, will be given randomly to one of the consumers ?

In case of rebalance, the partitions may get shuffled among consumers but
then again they should get divided into 2 disjoint sets one for each
consumer.

Reply via email to