@Override
  public void appendAll(List<ExtendedCell> cellList) throws IOException {
    if (historicalFilePath == null) {
      // The dual writing is not enabled and all cells are written to one file. We use
      // the live version file in this case
      for (ExtendedCell cell : cellList) {
        liveFileWriter.append(cell);
      }
      return;
    }
    if (cellList.isEmpty()) {
      return;
    }
    if (lastCell != null && comparator.compareRows(lastCell, cellList.get(0)) != 0) {
      // It is a new row and thus time to reset the state
      initRowState();
    }
    for (ExtendedCell cell : cellList) {
      appendCell(cell);
    }
  }
@param dir Directory to create file in.
@return random filename inside passed <code>dir</code>
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/StoreFileWriter.java