@Deprecated public class JredisConnectionFactory extends Object implements InitializingBean, DisposableBean, RedisConnectionFactory
| Constructor and Description |
|---|
JredisConnectionFactory()
Deprecated.
Constructs a new
JredisConnectionFactory instance. |
JredisConnectionFactory(org.jredis.connector.ConnectionSpec connectionSpec)
Deprecated.
Constructs a new
JredisConnectionFactory instance. |
JredisConnectionFactory(Pool<org.jredis.JRedis> pool)
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
void |
afterPropertiesSet()
Deprecated.
|
void |
destroy()
Deprecated.
|
RedisClusterConnection |
getClusterConnection()
Deprecated.
Provides a suitable connection for interacting with Redis Cluster.
|
RedisConnection |
getConnection()
Deprecated.
Provides a suitable connection for interacting with Redis.
|
boolean |
getConvertPipelineAndTxResults()
Deprecated.
JredisConnection does not support pipeline or transactions |
int |
getDatabase()
Deprecated.
Returns the index of the database.
|
String |
getHostName()
Deprecated.
Returns the Redis host name of this factory.
|
String |
getPassword()
Deprecated.
Returns the password used for authenticating with the Redis server.
|
int |
getPort()
Deprecated.
Returns the Redis port.
|
RedisSentinelConnection |
getSentinelConnection()
Deprecated.
Provides a suitable connection for interacting with Redis Sentinel.
|
protected RedisConnection |
postProcessConnection(JredisConnection connection)
Deprecated.
Post process a newly retrieved connection.
|
void |
setDatabase(int index)
Deprecated.
Sets the index of the database used by this connection factory.
|
void |
setHostName(String hostName)
Deprecated.
Sets the Redis host name for this factory.
|
void |
setPassword(String password)
Deprecated.
Sets the password used for authenticating with the Redis server.
|
void |
setPort(int port)
Deprecated.
Sets the Redis port.
|
DataAccessException |
translateExceptionIfPossible(RuntimeException ex)
Deprecated.
|
public JredisConnectionFactory()
JredisConnectionFactory instance.public JredisConnectionFactory(org.jredis.connector.ConnectionSpec connectionSpec)
JredisConnectionFactory instance. Will override the other connection parameters
passed to the factory.connectionSpec - already configured connection.public JredisConnectionFactory(Pool<org.jredis.JRedis> pool)
public void afterPropertiesSet()
afterPropertiesSet in interface InitializingBeanpublic void destroy()
throws Exception
destroy in interface DisposableBeanExceptionpublic RedisConnection getConnection()
RedisConnectionFactorygetConnection in interface RedisConnectionFactorypublic RedisClusterConnection getClusterConnection()
RedisConnectionFactorygetClusterConnection in interface RedisConnectionFactoryprotected RedisConnection postProcessConnection(JredisConnection connection)
connection - public DataAccessException translateExceptionIfPossible(RuntimeException ex)
translateExceptionIfPossible in interface PersistenceExceptionTranslatorpublic String getHostName()
public void setHostName(String hostName)
hostName - The hostName to set.public int getPort()
public void setPort(int port)
port - The port to set.public String getPassword()
public void setPassword(String password)
password - the password to setpublic int getDatabase()
public void setDatabase(int index)
index - database indexpublic boolean getConvertPipelineAndTxResults()
JredisConnection does not support pipeline or transactionsgetConvertPipelineAndTxResults in interface RedisConnectionFactorypublic RedisSentinelConnection getSentinelConnection()
RedisConnectionFactorygetSentinelConnection in interface RedisConnectionFactoryCopyright © 2011–2018 Pivotal Software, Inc.. All rights reserved.