private List<Future<Integer>> insertBlobs(final FeatureSource source, final Query baseQuery,
final ExecutorService executorService, final ProgressListener listener,
final @Nullable Long collectionSize, int nTasks, RevTreeBuilder2 builder) {
int partitionSize = 0;
BulkOpListener bulkOpListener;
if (collectionSize == null) {
nTasks = 1;
partitionSize = Integer.MAX_VALUE;
bulkOpListener = BulkOpListener.NOOP_LISTENER;
} else {
final int total = collectionSize.intValue();
partitionSize = total / nTasks;
bulkOpListener = new BulkOpListener() {
int inserted = 0;
@Override
public synchronized void inserted(ObjectId object,
@Nullable Integer storageSizeBytes) {