private void failBatch(
        ProducerBatch batch,
        RuntimeException topLevelException,
        boolean adjustSequenceNumbers
    ) {
        failBatch(batch, topLevelException, batchIndex -> topLevelException, adjustSequenceNumbers);
    }
Format the error from a {@link ProduceResponse.PartitionResponse} in a user-friendly string
e.g "NETWORK_EXCEPTION. Error Message: Disconnected from node 0"
clients/src/main/java/org/apache/kafka/clients/producer/internals/Sender.java