Skip to content

Commit d51094d

Browse files
vasukiseshbenjamin-bader
authored andcommitted
Use configured timeout value as the time to wait for a connection from the pool. (#53)
1 parent 5099e55 commit d51094d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

dropwizard-redis/src/main/java/com/bendb/dropwizard/redis/JedisFactory.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@ public JedisPool build(Environment environment) {
164164
poolConfig.setMinIdle(getMinIdle());
165165
poolConfig.setMaxIdle(getMaxIdle());
166166
poolConfig.setMaxTotal(getMaxTotal());
167+
poolConfig.setMaxWaitMillis(getTimeout()); // Use configured timeout value as the time to wait for a connection
167168

168169
final JedisPool pool = new JedisPool(poolConfig, getHost(), getPort(), getTimeout(), getPassword(), ssl);
169170

0 commit comments

Comments
 (0)