@Override
    public void write(DataOutput dataOutput) throws IOException {
      dataOutput.writeLong(length);
      dataOutput.writeInt(locations.size());
      for (int i = 0; i < locations.size(); i++) {
        dataOutput.writeInt(locations.get(i).length());
        dataOutput.writeBytes(locations.get(i));
      }
      dataOutput.writeInt(bucketNum);
      if (base == null) {
        dataOutput.writeInt(0);
      } else {
        dataOutput.writeInt(base.toString().length());
        dataOutput.writeBytes(base.toString());
        Integer attemptId = deltasToAttemptId.get(base.getName());
        if (attemptId == null) {
          dataOutput.writeInt(0);
        } else {
          dataOutput.writeInt(attemptId.toString().length());
          dataOutput.writeBytes(attemptId.toString());
        }
      }
      dataOutput.writeInt(deltas.length);
      for (int i = 0; i < deltas.length; i++) {
        dataOutput.writeInt(deltas[i].toString().length());
        dataOutput.writeBytes(deltas[i].toString());
        Integer attemptId = deltasToAttemptId.get(deltas[i].getName());
        if (attemptId == null) {
          dataOutput.writeInt(0);
        } else {
          dataOutput.writeInt(attemptId.toString().length());
          dataOutput.writeBytes(attemptId.toString());
        }
      }

    }
@param hadoopConf
@param bucket bucket to be processed by this split
@param files actual files this split should process.  It is assumed the caller has already
             parsed out the files in base and deltas to populate this list.  Includes copy_N
@param base directory of the base, or the partition/table location if the files are in old
            style.  Can be null.
@param deltas directories of the delta files.
@throws IOException
ql/src/java/org/apache/hadoop/hive/ql/txn/compactor/MRCompactor.java