public BinaryOperator<List<T>> combiner() {
        return (ts, ots) -> {
            // process each parallel list without checking for batch size
            // avoids adding all elements of one to another
            // can be modified if a strict batching mode is required
            batchProcessor.accept(ts);
            batchProcessor.accept(ots);
            recordsProcessed.addAndGet(ts.size() + ots.size());
            return Collections.emptyList();
        };
    }
Creates a new batch collector

@param batchSize      the batch size after which the batchProcessor should be called
@param batchProcessor the batch processor which accepts batches of records to process
@param <T>            the type of elements being processed
@return a batch collector instance
stroom-util/src/main/java/stroom/util/collections/BatchingCollector.java