User Tools

Site Tools


java:java

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

java:java [2022/07/26 07:20] – [Thread pools] adminjava:java [2022/10/29 16:15] (current) – external edit 127.0.0.1
Line 562: Line 562:
   * **Atomic variables** have features that minimize synchronization and help avoid memory consistency errors.   * **Atomic variables** have features that minimize synchronization and help avoid memory consistency errors.
   * **ThreadLocalRandom** (in JDK 7) provides **efficient generation of pseudorandom numbers from multiple threads**.   * **ThreadLocalRandom** (in JDK 7) provides **efficient generation of pseudorandom numbers from multiple threads**.
-=== Executor Interfaces === + 
-=== Thread pools ===+==== Thread pools ====
 {{:java:thread-pool-tasks.png|}} {{:java:thread-pool-tasks.png|}}
 refer:  refer: 
-  * https://docs.oracle.com/javase/tutorial/essential/concurrency/pools.html 
-  * http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ThreadPoolExecutor.html 
   * https://www.baeldung.com/thread-pool-java-and-guava   * https://www.baeldung.com/thread-pool-java-and-guava
   * http://howtodoinjava.com/2012/10/20/how-to-use-blockingqueue-and-threadpoolexecutor-in-java   * http://howtodoinjava.com/2012/10/20/how-to-use-blockingqueue-and-threadpoolexecutor-in-java
 +  * http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ThreadPoolExecutor.html
 Thread pools address two different problems:  Thread pools address two different problems: 
   * They usually provide improved performance when **executing large numbers of asynchronous tasks**, due to reduced per-task invocation overhead   * They usually provide improved performance when **executing large numbers of asynchronous tasks**, due to reduced per-task invocation overhead
java/java.1658820018.txt.gz · Last modified: 2022/10/29 16:15 (external edit)