public boolean isValid() {
        return sizeInBytes() >= RECORD_OVERHEAD_V0 && checksum() == computeChecksum();
    }
Returns true if the crc stored with the record matches the crc computed off the record contents
clients/src/main/java/org/apache/kafka/common/record/LegacyRecord.java