public long getFirstBatchTimestamp() {
        loadFirstBatchTimestamp();
        OptionalLong timestamp = rollingBasedTimestamp;
        if (timestamp.isPresent() && timestamp.getAsLong() >= 0)
            return timestamp.getAsLong();
        return Long.MAX_VALUE;
    }
@return the first batch timestamp if the timestamp is available. Otherwise, return Long.MaxValue
storage/src/main/java/org/apache/kafka/storage/internals/log/LogSegment.java