public static List<Module> loadModules(final Iterable<String> moduleIdentifiers, final File... repoRoots) {
final Pool pool = Resources.getPoolHandle();
final ExecutorService exec = pool.aquireExec();
final Properties origProps = snapshotProps();
try {
final LocalModuleLoader loader = new LocalModuleLoader(repoRoots);
final List<Future<Module>> asyncModules = new LinkedList<Future<Module>>();
for (final String moduleIdentifier : moduleIdentifiers) {
asyncModules.add(exec.submit(new Callable<Module>() {
@Override
public Module call() throws Exception {
return loader.loadModule(ModuleIdentifier.fromString(moduleIdentifier));
}
}));
}
final List<Module> modules = new ArrayList<Module>(asyncModules.size());