public static class FlinkJedisSentinelConfig.Builder extends Object
FlinkJedisSentinelConfig
.Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
FlinkJedisSentinelConfig |
build()
Builds JedisSentinelConfig.
|
FlinkJedisSentinelConfig.Builder |
setConnectionTimeout(int connectionTimeout)
Sets connection timeout.
|
FlinkJedisSentinelConfig.Builder |
setDatabase(int database)
Sets database index.
|
FlinkJedisSentinelConfig.Builder |
setMasterName(String masterName)
Sets master name of the replica set.
|
FlinkJedisSentinelConfig.Builder |
setMaxIdle(int maxIdle)
Sets value for the
maxIdle configuration attribute
for pools to be created with this configuration instance. |
FlinkJedisSentinelConfig.Builder |
setMaxTotal(int maxTotal)
Sets value for the
maxTotal configuration attribute
for pools to be created with this configuration instance. |
FlinkJedisSentinelConfig.Builder |
setMinIdle(int minIdle)
Sets value for the
minIdle configuration attribute
for pools to be created with this configuration instance. |
FlinkJedisSentinelConfig.Builder |
setPassword(String password)
Sets password.
|
FlinkJedisSentinelConfig.Builder |
setSentinels(Set<String> sentinels)
Sets sentinels address.
|
FlinkJedisSentinelConfig.Builder |
setSoTimeout(int soTimeout)
Sets socket timeout.
|
public FlinkJedisSentinelConfig.Builder setMasterName(String masterName)
masterName
- master name of the replica setpublic FlinkJedisSentinelConfig.Builder setSentinels(Set<String> sentinels)
sentinels
- host set of the sentinelspublic FlinkJedisSentinelConfig.Builder setConnectionTimeout(int connectionTimeout)
connectionTimeout
- connection timeout, default value is 2000public FlinkJedisSentinelConfig.Builder setSoTimeout(int soTimeout)
soTimeout
- socket timeout, default value is 2000public FlinkJedisSentinelConfig.Builder setPassword(String password)
password
- password, if anypublic FlinkJedisSentinelConfig.Builder setDatabase(int database)
database
- database index, default value is 0public FlinkJedisSentinelConfig.Builder setMaxTotal(int maxTotal)
maxTotal
configuration attribute
for pools to be created with this configuration instance.maxTotal
- maxTotal the maximum number of objects that can be allocated by the pool, default value is 8public FlinkJedisSentinelConfig.Builder setMaxIdle(int maxIdle)
maxIdle
configuration attribute
for pools to be created with this configuration instance.maxIdle
- the cap on the number of "idle" instances in the pool, default value is 8public FlinkJedisSentinelConfig.Builder setMinIdle(int minIdle)
minIdle
configuration attribute
for pools to be created with this configuration instance.minIdle
- the minimum number of idle objects to maintain in the pool, default value is 0public FlinkJedisSentinelConfig build()
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.