callables = wrapWithStatsCallables(callables, noEstimateCounter);
int numProcessors = Runtime.getRuntime().availableProcessors();
ExecutorService executor = Executors.newFixedThreadPool(numProcessors);
log.info("Starting timing of {} tasks in {} threads", callables.size(), numProcessors);
try {
List<Future<Void>> futures = executor.invokeAll(callables);
// Go look for exceptions here, really
for (Future<Void> future : futures) {
future.get();
}
} catch (InterruptedException ie) {