All Downloads are FREE. Search and download functionalities are using the official Maven repository.

redis.clients.jedis.JedisPoolConfig Maven / Gradle / Ivy

The newest version!
package redis.clients.jedis;

import java.time.Duration;
import org.apache.commons.pool2.impl.GenericObjectPoolConfig;

public class JedisPoolConfig extends GenericObjectPoolConfig {

  public JedisPoolConfig() {
    // defaults to make your life with connection pool easier :)
    setTestWhileIdle(true);
    setMinEvictableIdleTime(Duration.ofMillis(60000));
    setTimeBetweenEvictionRuns(Duration.ofMillis(30000));
    setNumTestsPerEvictionRun(-1);
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy