private void maybeAbortBatches(RuntimeException exception) {
        if (accumulator.hasIncomplete()) {
            log.error("Aborting producer batches due to fatal error", exception);
            accumulator.abortBatches(exception);
        }
    }
Returns true if a transactional request is sent or polled, or if a FindCoordinator request is enqueued
clients/src/main/java/org/apache/kafka/clients/producer/internals/Sender.java