Lianet Magrans created KAFKA-16984: -------------------------------------- Summary: New consumer should wait for leave group response to avoid responses to disconnected clients Key: KAFKA-16984 URL: https://issues.apache.org/jira/browse/KAFKA-16984 Project: Kafka Issue Type: Bug Components: consumer Affects Versions: 3.8.0 Reporter: Lianet Magrans Assignee: Lianet Magrans
When the new consumer attempts to leave a group, it sends a leave group request in a fire-and-forget mode, so it transitions to UNSUBSCRIBED as soon as it generates the requests (without waiting for a response. Note that this transition to unsubscribe marks the leave operation as completed. This makes that, when leaving a group while closing a consumer, the member sends the leave request and moves on to next operation, which is closing the network thread, so we end up with disconnected client receiving responses from the server. We should send leave group heartbeat, and transition to UNSUBSCRIBE (completes the leave operation) only when we get a response for it, which is a much more accurate confirmation that the consumer left the group and can move on with other operations -- This message was sent by Atlassian Jira (v8.20.10#820010)