kaffe icon indicating copy to clipboard operation
kaffe copied to clipboard

Receives notification when rebalance in progress/assignments revoked

Open Leesanwei opened this issue 5 years ago • 2 comments

Hi, We are dealing with some scaling issues where if we have another consumer coming up in the same consumer group, we would like to delete some old cache. In order to do this, we would need to receive a notification when a rebalance is in progress and we'll also have to know what partitions each consumer gets. Would this be possible?

Thanks!

Leesanwei avatar Jul 21 '20 13:07 Leesanwei

That would definitely require some changes to Kaffe. 🤔 We'd be open to a PR on that. Not really even sure how to design it, but the notification might need to happen in either Kaffe.Subscriber or Kaffe.GroupMember.

objectuser avatar Jul 21 '20 13:07 objectuser

I am working on this for our use case. I made some changes and it seemed to work for us. Could someone please take a look at the PR - https://github.com/spreedly/kaffe/pull/108/files?

PS: This is the first time I'm working with Elixir and please don't mind if I made any obvious mistakes.

harshagelivi avatar Feb 04 '21 12:02 harshagelivi