@Override
    public boolean equals(Object o) {
        if (this == o)
            return true;
        if (o == null || getClass() != o.getClass())
            return false;

        SimpleRecord that = (SimpleRecord) o;
        return timestamp == that.timestamp &&
                Objects.equals(key, that.key) &&
                Objects.equals(value, that.value) &&
                Arrays.equals(headers, that.headers);
    }
High-level representation of a kafka record. This is useful when building record sets to
avoid depending on a specific magic version.
clients/src/main/java/org/apache/kafka/common/record/SimpleRecord.java