List of usage examples for com.google.common.util.concurrent Striped semaphore
public static Striped<Semaphore> semaphore(int stripes, final int permits)
From source file:com.squid.kraken.v4.core.database.impl.HikariDataSourceReliable.java
public HikariDataSourceReliable() { super();// w w w . j a va 2 s .com this.semaphore = Striped.semaphore(1, maximumPoolSize); //same than the number of connection in the pool super.setMaximumPoolSize(maximumPoolSize); super.setMinimumIdle(0);// limit the number of idle connection to the minimum, this is not a bottleneck for Bouquet use-case }