private void onResponse(final ConsumerGroupHeartbeatResponse response, long currentTimeMs) {
        if (Errors.forCode(response.data().errorCode()) == Errors.NONE) {
            heartbeatRequestState.updateHeartbeatIntervalMs(response.data().heartbeatIntervalMs());
            heartbeatRequestState.onSuccessfulAttempt(currentTimeMs);
            membershipManager.onHeartbeatSuccess(response.data());
            return;
        }
        onErrorResponse(response, currentTimeMs);
    }
Reset the poll timer, indicating that the user has called consumer.poll(). If the member
is in {@link MemberState#STALE} state due to expired poll timer, this will transition the
member to {@link MemberState#JOINING}, so that it rejoins the group.
clients/src/main/java/org/apache/kafka/clients/consumer/internals/HeartbeatRequestManager.java