@Override
    public long timestamp() {
        return timestamp;
    }
This class implements the inner record format for magic 2 and above. The schema is as follows:


Record =>
  Length => Varint
  Attributes => Int8
  TimestampDelta => Varlong
  OffsetDelta => Varint
  Key => Bytes
  Value => Bytes
  Headers => [HeaderKey HeaderValue]
    HeaderKey => String
    HeaderValue => Bytes

Note that in this schema, the Bytes and String types use a variable length integer to represent
the length of the field. The array type used for the headers also uses a Varint for the number of
headers.

The current record attributes are depicted below:

 ----------------
 | Unused (0-7) |
 ----------------

The offset and timestamp deltas compute the difference relative to the base offset and
base timestamp of the batch that this record is contained in.
clients/src/main/java/org/apache/kafka/common/record/DefaultRecord.java