public class JedisPoolConfig extends Object implements Serializable
Configuration for JedisPool.
Modifier and Type | Class and Description |
---|---|
static class |
JedisPoolConfig.Builder
Builder for initializing JedisPoolConfig.
|
Constructor and Description |
---|
JedisPoolConfig() |
JedisPoolConfig(String host,
int port,
int timeout,
String password,
int database)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
getDatabase()
Returns database index.
|
String |
getHost()
Returns host.
|
String |
getPassword()
Returns password.
|
int |
getPort()
Returns port.
|
int |
getTimeout()
Returns timeout.
|
String |
toString() |
public JedisPoolConfig()
public JedisPoolConfig(String host, int port, int timeout, String password, int database)
Constructor.
You can use JedisPoolConfig.Builder() for leaving some fields to apply default value.host
- hostname or IPport
- porttimeout
- socket / connection timeoutdatabase
- database indexpassword
- password, if anypublic String getHost()
Returns host.
public int getPort()
Returns port.
public int getTimeout()
Returns timeout.
public int getDatabase()
Returns database index.
public String getPassword()
Returns password.
Copyright © 2019 The Apache Software Foundation. All rights reserved.