masterreplica package with version 6.@Deprecated public class MasterSlaveConnectionProvider<K,V> extends Object
| Modifier and Type | Method and Description |
|---|---|
protected Collection<StatefulRedisConnection<K,V>> |
allConnections()
Deprecated.
|
void |
close()
Deprecated.
Close all connections.
|
CompletableFuture<Void> |
closeAsync()
Deprecated.
Close all connections asynchronously.
|
void |
closeStaleConnections()
Deprecated.
Close stale connections.
|
void |
flushCommands()
Deprecated.
Flush pending commands on all connections.
|
StatefulRedisConnection<K,V> |
getConnection(io.lettuce.core.masterslave.MasterSlaveConnectionProvider.Intent intent)
Deprecated.
Retrieve a
StatefulRedisConnection by the intent. |
protected CompletableFuture<StatefulRedisConnection<K,V>> |
getConnection(RedisNodeDescription redisNodeDescription)
Deprecated.
|
CompletableFuture<StatefulRedisConnection<K,V>> |
getConnectionAsync(io.lettuce.core.masterslave.MasterSlaveConnectionProvider.Intent intent)
Deprecated.
Retrieve a
StatefulRedisConnection by the intent. |
protected long |
getConnectionCount()
Deprecated.
|
RedisNodeDescription |
getMaster()
Deprecated.
|
ReadFrom |
getReadFrom()
Deprecated.
|
void |
reset()
Deprecated.
Reset the command state of all connections.
|
void |
setAutoFlushCommands(boolean autoFlush)
Deprecated.
Disable or enable auto-flush behavior for all connections.
|
void |
setKnownNodes(Collection<RedisNodeDescription> knownNodes)
Deprecated.
|
void |
setReadFrom(ReadFrom readFrom)
Deprecated.
|
public StatefulRedisConnection<K,V> getConnection(io.lettuce.core.masterslave.MasterSlaveConnectionProvider.Intent intent)
StatefulRedisConnection by the intent.
MasterSlaveConnectionProvider.Intent.WRITE intentions use the master connection,
MasterSlaveConnectionProvider.Intent.READ intentions lookup one or more read
candidates using the ReadFrom setting.intent - command intent.public CompletableFuture<StatefulRedisConnection<K,V>> getConnectionAsync(io.lettuce.core.masterslave.MasterSlaveConnectionProvider.Intent intent)
StatefulRedisConnection by the intent.
MasterSlaveConnectionProvider.Intent.WRITE intentions use the master connection,
MasterSlaveConnectionProvider.Intent.READ intentions lookup one or more read
candidates using the ReadFrom setting.intent - command intent.RedisException - if the host is not part of the clusterprotected CompletableFuture<StatefulRedisConnection<K,V>> getConnection(RedisNodeDescription redisNodeDescription)
protected long getConnectionCount()
public void closeStaleConnections()
public void reset()
StatefulConnection.reset()public void close()
public CompletableFuture<Void> closeAsync()
public void flushCommands()
StatefulConnection.flushCommands()public void setAutoFlushCommands(boolean autoFlush)
autoFlush - state of autoFlush.StatefulConnection.setAutoFlushCommands(boolean)@Deprecated protected Collection<StatefulRedisConnection<K,V>> allConnections()
public void setKnownNodes(Collection<RedisNodeDescription> knownNodes)
knownNodes - public ReadFrom getReadFrom()
public void setReadFrom(ReadFrom readFrom)
public RedisNodeDescription getMaster()
Copyright © 2021 lettuce.io. All rights reserved.