@Override
      protected Pair<List<LoadQueueItem>, String> groupOrSplit(AsyncClusterConnection conn,
        TableName tableName, Multimap<ByteBuffer, LoadQueueItem> regionGroups, LoadQueueItem item,
        List<Pair<byte[], byte[]>> startEndKeys) throws IOException {
        Pair<List<LoadQueueItem>, String> lqis =
          super.groupOrSplit(conn, tableName, regionGroups, item, startEndKeys);
        if (lqis != null && lqis.getFirst() != null) {
          countedLqis.addAndGet(lqis.getFirst().size());
        }
        return lqis;
      }
This test splits a table and attempts to bulk load. The bulk import files should be split
before atomically importing.
hbase-server/src/test/java/org/apache/hadoop/hbase/tool/TestBulkLoadHFilesSplitRecovery.java