public class CommandAsyncService extends Object implements CommandAsyncExecutor
Modifier and Type | Field and Description |
---|---|
protected RedissonClient |
redisson |
protected RedissonReactiveClient |
redissonReactive |
Constructor and Description |
---|
CommandAsyncService(ConnectionManager connectionManager) |
Modifier and Type | Method and Description |
---|---|
protected <V,R> void |
async(boolean readOnlyMode,
NodeSource source,
Codec codec,
RedisCommand<V> command,
Object[] params,
RPromise<R> mainPromise,
int attempt) |
boolean |
await(RFuture<?> future,
long timeout,
TimeUnit timeoutUnit) |
<V> RedisException |
convertException(RFuture<V> future) |
CommandAsyncExecutor |
enableRedissonReferenceSupport(RedissonClient redisson) |
CommandAsyncExecutor |
enableRedissonReferenceSupport(RedissonReactiveClient redissonReactive) |
<T,R> RFuture<R> |
evalAllAsync(boolean readOnlyMode,
RedisCommand<T> command,
SlotCallback<T,R> callback,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalReadAsync(InetSocketAddress client,
String key,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalReadAsync(Integer slot,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalReadAsync(MasterSlaveEntry entry,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalReadAsync(String key,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalWriteAllAsync(RedisCommand<T> command,
SlotCallback<T,R> callback,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalWriteAsync(Integer slot,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalWriteAsync(MasterSlaveEntry entry,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<T,R> RFuture<R> |
evalWriteAsync(String key,
Codec codec,
RedisCommand<T> evalCommandType,
String script,
List<Object> keys,
Object... params) |
<V> V |
get(RFuture<V> future) |
ConnectionManager |
getConnectionManager() |
boolean |
isRedissonReferenceSupportEnabled() |
<T,R> RFuture<Collection<R>> |
readAllAsync(RedisCommand<T> command,
Object... params) |
<R,T> RFuture<R> |
readAllAsync(RedisCommand<T> command,
SlotCallback<T,R> callback,
Object... params) |
<T,R> RFuture<R> |
readAsync(InetSocketAddress client,
MasterSlaveEntry entry,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readAsync(InetSocketAddress client,
String key,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readAsync(Integer slot,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readAsync(MasterSlaveEntry entry,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readAsync(String key,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readAsync(String key,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
readRandomAsync(RedisCommand<T> command,
Object... params) |
protected <V,R> void |
releaseConnection(NodeSource source,
RFuture<RedisConnection> connectionFuture,
boolean isReadOnly,
RPromise<R> attemptPromise,
AsyncDetails<V,R> details) |
void |
syncSubscription(RFuture<?> future) |
<T> RFuture<Void> |
writeAllAsync(RedisCommand<T> command,
Object... params) |
<R,T> RFuture<R> |
writeAllAsync(RedisCommand<T> command,
SlotCallback<T,R> callback,
Object... params) |
<T,R> RFuture<R> |
writeAsync(Integer slot,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
writeAsync(MasterSlaveEntry entry,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
writeAsync(String key,
Codec codec,
RedisCommand<T> command,
Object... params) |
<T,R> RFuture<R> |
writeAsync(String key,
RedisCommand<T> command,
Object... params) |
protected RedissonClient redisson
protected RedissonReactiveClient redissonReactive
public CommandAsyncService(ConnectionManager connectionManager)
public ConnectionManager getConnectionManager()
getConnectionManager
in interface CommandAsyncExecutor
public CommandAsyncExecutor enableRedissonReferenceSupport(RedissonClient redisson)
enableRedissonReferenceSupport
in interface CommandAsyncExecutor
public CommandAsyncExecutor enableRedissonReferenceSupport(RedissonReactiveClient redissonReactive)
enableRedissonReferenceSupport
in interface CommandAsyncExecutor
public boolean isRedissonReferenceSupportEnabled()
isRedissonReferenceSupportEnabled
in interface CommandAsyncExecutor
public void syncSubscription(RFuture<?> future)
syncSubscription
in interface CommandAsyncExecutor
public <V> V get(RFuture<V> future)
get
in interface CommandAsyncExecutor
public boolean await(RFuture<?> future, long timeout, TimeUnit timeoutUnit) throws InterruptedException
await
in interface CommandAsyncExecutor
InterruptedException
public <T,R> RFuture<R> readAsync(InetSocketAddress client, MasterSlaveEntry entry, Codec codec, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readAsync(InetSocketAddress client, String key, Codec codec, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<Collection<R>> readAllAsync(RedisCommand<T> command, Object... params)
readAllAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readRandomAsync(RedisCommand<T> command, Object... params)
readRandomAsync
in interface CommandAsyncExecutor
public <T> RFuture<Void> writeAllAsync(RedisCommand<T> command, Object... params)
writeAllAsync
in interface CommandAsyncExecutor
public <R,T> RFuture<R> writeAllAsync(RedisCommand<T> command, SlotCallback<T,R> callback, Object... params)
writeAllAsync
in interface CommandAsyncExecutor
public <R,T> RFuture<R> readAllAsync(RedisCommand<T> command, SlotCallback<T,R> callback, Object... params)
readAllAsync
in interface CommandAsyncExecutor
public <V> RedisException convertException(RFuture<V> future)
convertException
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readAsync(String key, Codec codec, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readAsync(MasterSlaveEntry entry, Codec codec, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readAsync(Integer slot, Codec codec, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> writeAsync(MasterSlaveEntry entry, Codec codec, RedisCommand<T> command, Object... params)
writeAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> writeAsync(Integer slot, Codec codec, RedisCommand<T> command, Object... params)
writeAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> readAsync(String key, RedisCommand<T> command, Object... params)
readAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalReadAsync(String key, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalReadAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalReadAsync(MasterSlaveEntry entry, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalReadAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalReadAsync(Integer slot, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalReadAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalReadAsync(InetSocketAddress client, String key, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalReadAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalWriteAsync(String key, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalWriteAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalWriteAsync(MasterSlaveEntry entry, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalWriteAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalWriteAsync(Integer slot, Codec codec, RedisCommand<T> evalCommandType, String script, List<Object> keys, Object... params)
evalWriteAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalWriteAllAsync(RedisCommand<T> command, SlotCallback<T,R> callback, String script, List<Object> keys, Object... params)
evalWriteAllAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> evalAllAsync(boolean readOnlyMode, RedisCommand<T> command, SlotCallback<T,R> callback, String script, List<Object> keys, Object... params)
public <T,R> RFuture<R> writeAsync(String key, RedisCommand<T> command, Object... params)
writeAsync
in interface CommandAsyncExecutor
public <T,R> RFuture<R> writeAsync(String key, Codec codec, RedisCommand<T> command, Object... params)
writeAsync
in interface CommandAsyncExecutor
protected <V,R> void async(boolean readOnlyMode, NodeSource source, Codec codec, RedisCommand<V> command, Object[] params, RPromise<R> mainPromise, int attempt)
protected <V,R> void releaseConnection(NodeSource source, RFuture<RedisConnection> connectionFuture, boolean isReadOnly, RPromise<R> attemptPromise, AsyncDetails<V,R> details)
Copyright © 2014–2017 The Redisson Project. All rights reserved.