Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions kafka/coordinator/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -990,6 +990,11 @@ def _run_once(self):
# foreground thread has stalled in between calls to
# poll(), so we explicitly leave the group.
log.warning('Heartbeat poll expired, leaving group')
### XXX
# maybe_leave_group acquires client + coordinator lock;
# if we hold coordinator lock before calling, we risk deadlock
# release() is safe here because this is the last code in the current context
self.coordinator._lock.release()
self.coordinator.maybe_leave_group()

elif not self.coordinator.heartbeat.should_heartbeat():
Expand Down