public void onHeartbeatRequestSkipped() {
        if (state == MemberState.LEAVING) {
            log.debug("Heartbeat for leaving group could not be sent. Member {} with epoch {} will transition to {}.",
                    memberId, memberEpoch, MemberState.UNSUBSCRIBED);
            transitionToUnsubscribed();
        }
    }
Transition out of the {@link MemberState#LEAVING} state even if the heartbeat was not sent.
This will ensure that the member is not blocked in {@link MemberState#LEAVING} (it's the best
effort to send the request, without any response handling or retry logic).
clients/src/main/java/org/apache/kafka/clients/consumer/internals/ShareMembershipManager.java