InputStream is = getClass().getResourceAsStream("/test-url-list.txt");
BufferedReader br = new BufferedReader(new InputStreamReader(is));
String line;
int nurls = 0;
ExecutorService executor = Executors.newFixedThreadPool(100);
ExecutionList tasks = new ExecutionList();
while ((line = br.readLine()) != null) {
tasks.add(new LoadTask(t, line), executor);
nurls++;
}
long t0 = System.currentTimeMillis();
tasks.execute();
executor.awaitTermination(30, TimeUnit.SECONDS);
long el = System.currentTimeMillis() - t0;
System.err.println(nurls + " urls, time=" + el + "ms (" + (nurls / (el / 1000.0)) + " URI/s");
}