@Override
    protected void cleanup(Context context) throws IOException, InterruptedException {
      if (mapperException == null) {
        try {
          finishRemainingHashRanges(context);
        } catch (Throwable t) {
          mapperException = t;
        }
      }

      try {
        sourceTable.close();
        targetTable.close();
        sourceConnection.close();
        targetConnection.close();
      } catch (Throwable t) {
        if (mapperException == null) {
          mapperException = t;
        } else {
          LOG.error("Suppressing exception from closing tables", t);
        }
      }

      // propagate first exception
      if (mapperException != null) {
        Throwables.throwIfInstanceOf(mapperException, IOException.class);
        Throwables.throwIfInstanceOf(mapperException, InterruptedException.class);
        Throwables.throwIfUnchecked(mapperException);
      }
    }
Compare families, qualifiers, and timestamps of the given Cells. They are assumed to be of
the same row. Nulls are after non-nulls.
hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/SyncTable.java