executors java

Java
ExecutorService executor = Executors.newFixedThreadPool(10);

Source

Also in Java: