Closed xue610315921 closed 1 year ago
sometimes kafka decides to rebalance a consumer group doc says that in this case message channel will be closed closed channel return nil
@fxrlv so we need to restart the consumer manually or not? Thanks.
if you get nil from the message channel, you should return from ConsumeClaim
then check returned error from Consume method you called before
nil error means you can recall Consume and get new claims
Thank you for taking the time to raise this issue. However, it has not had any activity on it in the past 90 days and will be closed in 30 days if no updates occur. Please check if the main branch has already resolved the issue since it was raised. If you believe the issue is still valid and you would like input from the maintainers then please comment to ask for it to be reviewed.
github.com/Shopify/sarama v1.27.1
Versions
Configuration
Logs
logs: CLICK ME
``` no error log ```
Problem Description
Is this the correct way to implement the batch consuming? The code here:
Even I settled the rate limit to 50, the CPU usage of instance(docker) still would be 100%. Here is the pprof, I don't know why so many chanrecv here, and the lock & unlock in it cost a lot of resources.
In my memory when I was debugging, seems that I received a lot of
nil
from the channel(clainm.Message()), will it lead this? because I just continue when receiving nil. But I can't reproduce it on debugging machine now.Thanks a lot!