Collection<T> objs = createObj.collectObjects(rsp);
StopWatch updateWatch = new StopWatch().start();
int failed = bulkUpdate(objs, intoIndex, false, false).size();
// trying to enable flushing to avoid memory issues on the server side?
flush(intoIndex);
updateWatch.stop();
collectedResults += currentResults;
logger.info("Progress " + collectedResults + "/" + total + " fromIndex="
+ fromIndex + " update:" + updateWatch.totalTime().getSeconds() + " query:" + queryWatch.totalTime().getSeconds() + " failed:" + failed);
}
logger.info("Finished copying of index:" + fromIndex + ". Total:" + total + " collected:" + collectedResults);