Package org.nuxeo.ecm.core.redis
Class RedisFailoverExecutor
- java.lang.Object
-
- org.nuxeo.ecm.core.redis.RedisAbstractExecutor
-
- org.nuxeo.ecm.core.redis.RedisFailoverExecutor
-
- All Implemented Interfaces:
RedisExecutor
public class RedisFailoverExecutor extends RedisAbstractExecutor
-
-
Field Summary
Fields Modifier and Type Field Description protected RedisExecutor
executor
protected int
timeout
-
Fields inherited from class org.nuxeo.ecm.core.redis.RedisAbstractExecutor
scripts
-
-
Constructor Summary
Constructors Constructor Description RedisFailoverExecutor(int timeout, RedisExecutor base)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> T
execute(RedisCallable<T> callable)
protected <T> T
executeWithRetryPolicy(RedisCallable<T> callable, Retry.Policy policy)
redis.clients.util.Pool<redis.clients.jedis.Jedis>
getPool()
void
subscribe(redis.clients.jedis.JedisPubSub subscriber, String channel)
Run a subscriber, do not return.-
Methods inherited from class org.nuxeo.ecm.core.redis.RedisAbstractExecutor
evalsha, evalsha, scriptLoad
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nuxeo.ecm.core.redis.RedisExecutor
psubscribe, startMonitor, stopMonitor
-
-
-
-
Field Detail
-
timeout
protected final int timeout
-
executor
protected final RedisExecutor executor
-
-
Constructor Detail
-
RedisFailoverExecutor
public RedisFailoverExecutor(int timeout, RedisExecutor base)
-
-
Method Detail
-
execute
public <T> T execute(RedisCallable<T> callable) throws redis.clients.jedis.exceptions.JedisConnectionException
- Throws:
redis.clients.jedis.exceptions.JedisConnectionException
-
subscribe
public void subscribe(redis.clients.jedis.JedisPubSub subscriber, String channel) throws redis.clients.jedis.exceptions.JedisConnectionException
Description copied from interface:RedisExecutor
Run a subscriber, do not return.- Throws:
redis.clients.jedis.exceptions.JedisConnectionException
-
executeWithRetryPolicy
protected <T> T executeWithRetryPolicy(RedisCallable<T> callable, Retry.Policy policy)
-
getPool
public redis.clients.util.Pool<redis.clients.jedis.Jedis> getPool()
-
-