@Override
  public void readFields(DataInput in) throws IOException {
    short len = in.readShort();
    if (len < THREE_LONGS) throw new IOException("Need at least " + THREE_LONGS + " bytes");
    pathHash = in.readLong();
    modTime = in.readLong();
    length = in.readLong();
    int extraBytes = len - THREE_LONGS;
    if (extraBytes > 0) {
      in.skipBytes(extraBytes);
    }
  }
Length allows for some backward compatibility wrt field addition.
ql/src/java/org/apache/hadoop/hive/ql/io/SyntheticFileId.java