public boolean hasAnyPendingRequests() {
        return client.hasInFlightRequests() || !unsentRequests.isEmpty();
    }
Return true if there is at least one in-flight request or unsent request.
clients/src/main/java/org/apache/kafka/clients/consumer/internals/NetworkClientDelegate.java