简体   繁体   中英

Unable to get resource from jedis

After running my application, i am getting this error after around 5 mins. Even though i am returning the resource after use, i keep getting this. I have built jedis-2.2.2-SNAPSHOT.jar from the jedis code base, since its not released yet I had set the minIdle = 100, maxIdle=200 & maxActive=200. At the time of this exception, the connection count to redis was 122 from my application

redis.clients.jedis.exceptions.JedisConnectionException: Could not get a resource from the pool
    at redis.clients.util.Pool.getResource(Pool.java:42)
Caused by: java.util.NoSuchElementException: Timeout waiting for idle object
    at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:442)
    at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:360)
    at redis.clients.util.Pool.getResource(Pool.java:40)
    ... 6 more

Did you check that redis is still up & running ?

If not, investigate why it died.

try a redis-cli in a terminal if you can. "info" would give you more details.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM