java:java
Differences
This shows you the differences between two versions of the page.
java:java [2022/07/26 06:59] – [c3p0 connection pool] admin | java: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 ==== |
+ | {{: | ||
refer: | refer: | ||
- | * https://docs.oracle.com/javase/ | + | * https://www.baeldung.com/thread-pool-java-and-guava |
- | * http:// | + | |
* http:// | * http:// | ||
+ | * http:// | ||
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 | ||
Line 1252: | Line 1253: | ||
* {{: | * {{: | ||
- | ==== Hibernate connection pooling | + | ==== Default |
- | Below are basic steps config for connections in Hibernate(each connection in MySQL was a session in Hibernate): | + | Below are basic steps config for connections in Hibernate(each connection in MySQL was a session in Hibernate)(refer: https:// |
- Config max connections in MySQL: | - Config max connections in MySQL: | ||
* config temporary in MySQL Admin console:< | * config temporary in MySQL Admin console:< |
java/java.1658818793.txt.gz · Last modified: 2022/10/29 16:15 (external edit)