Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Offset commits during rebalance

  1. If a consumer receives a higher generation id for it's group, it stops fetching and commits existing offsets before sending a JoinGroupRequest to the co-ordinator.
  2. The co-ordinator checks the generation id in the OffsetCommitRequest and rejects it if the generation id in the request is higher than the generation id on the co-ordinator. This either indicates a bug in the consumer logic or a consumer with stale consumer metadata sending requests to the older co-ordinator.
  3. The co-ordinator does not allow offset commit requests with generation ids older than the current group generation id. This is done for multiple reasons. During rebalance, the co-ordinator would've incremented the generation id for the group to trigger a rebalance while the consumers would commit offsets with the previous generation id. Another way this can happen is if a consumer goes through a long GC pause while the consumer's group has gone through one or more rebalance operations. In this case, the consumer would still commit offsets using an older generation id until it