- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Kafka Consumer throwing error message "commit cannot be completed due to group rebalance"
- Labels:
-
Apache Kafka
-
Apache NiFi
Created ‎07-18-2017 01:32 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am getting an exception at the Kafka consumer as shown in the attached screenshot. and once the exception occurs at kafka consumer the flow files are becoming very slow at publishKafka and consumerKafka.
can I get help to understand the reason for causing the issue in Nifi consume kafka. I am not getting these kind of issues when I run kafka consumers standalone from terminal.
I wonder if I am missing some configuration in Nifi. I am also attaching my configuration properties for consume kafka.
consume-kafka-configuration.jpgkafka-consumer-error-message.jpg
Created ‎07-19-2017 03:07 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Looking at the error message it appears that issue is on Kafka side due to group re-balance. If you google this term you will get lots of useful information on this issue: "CommitFailedException Kafka group rebalance"
Created ‎07-19-2017 03:27 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I tried get some help from blogs. But I am unable to find the relevant information to resolve the issue.
It would be helpful if any one have configured Consumer Kafka processor in Nifi successfully to process thousands of records per minutes can share the way the processor is ocnfigured!
Thanks,
Anil.
Created ‎07-19-2017 03:33 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Can you please try create a topic and then use Kafka Console Producer to post data to that topic. Once done, please use Console Producer to read data to confirm if it works end to end without using NiFi
Created ‎07-20-2017 07:52 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@Anil Reddy
It looks like large processing time between poll calls ( when processor processes large volume of data) can exceed session.timeout.ms and cause group rebalancing. One way you can try is increasing the group.max.session.timeout.ms on the brokers side and add increased value of request.timeout.ms and session.timeout.ms in the ConsumeKafka configs.
Please let me know if it helps.
Thank you!
Created ‎07-20-2017 08:45 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
We have that flow running fine with out Nifi in our current setup. We are trying to migrate to Nifi, hence build the flow in Nifi using Consume Kafka.
Created ‎07-22-2017 01:41 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is your issue resolved? I just wrote a simple NiFi flow and used it to push 5000 records into Kafka and read those 5000 records out of Kafka. I did not get any error.
Created ‎08-17-2017 02:38 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Nope. issue is not resolved!
Created ‎07-23-2017 09:05 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Kafka server expects that it receives at least one heartbeat within the session time out. So the consumer tries to do a heartbeat at most (session time out/heartbeat times). Some heartbeats might be missed. So your heartbeat time should not be more than 1/3 of the session time out. ( refer to the docs)
Created ‎08-24-2017 03:44 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that makes sense. But I am unable to figureout where can I configure those parameters in ConsumeKafka_0_10 processors
