Explorar el Código

新加不带timeout跟password的构造方法,满足8/2需求。

建议生产环境都使用带poolConfig的构造方法,防止redis出现链接异常,可参考 bug
https://github.com/xetorthio/jedis/issues/848
master
bobbyguo hace 8 años
padre
commit
091e47897d
Se han modificado 1 ficheros con 5 adiciones y 0 borrados
  1. +5
    -0
      weixin-java-cp/src/main/java/me/chanjar/weixin/cp/api/WxCpJedisConfigStorage.java

+ 5
- 0
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/api/WxCpJedisConfigStorage.java Ver fichero

@@ -39,6 +39,11 @@ public class WxCpJedisConfigStorage implements WxCpConfigStorage {
this.jedisPool = new JedisPool(host, port);
}

public WxCpJedisConfigStorage(JedisPoolConfig poolConfig, String host, int port) {
this.jedisPool = new JedisPool(poolConfig, host, port);
}
public WxCpJedisConfigStorage(JedisPoolConfig poolConfig, String host, int port, int timeout, final String password) {
this.jedisPool = new JedisPool(poolConfig, host, port, timeout, password);
}


Cargando…
Cancelar
Guardar