public TxnIndexSearchResult collectAbortedTxns(long fetchOffset, long upperBoundOffset) {
        return txnIndex.collectAbortedTxns(fetchOffset, upperBoundOffset);
    }
Check whether the last offset of the last batch in this segment overflows the indexes.
storage/src/main/java/org/apache/kafka/storage/internals/log/LogSegment.java