Package io.lettuce.core.support
Class BasePoolConfig
- java.lang.Object
-
- io.lettuce.core.support.BasePoolConfig
-
- Direct Known Subclasses:
BoundedPoolConfig
public abstract class BasePoolConfig extends Object
Base configuration for an object pool declaring options for object validation. Typically used as base class for configuration objects for specific pool implementations.- Since:
- 5.1
- Author:
- Mark Paluch
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BasePoolConfig.Builder
Builder forBasePoolConfig
.
-
Field Summary
Fields Modifier and Type Field Description static boolean
DEFAULT_TEST_ON_ACQUIRE
The default value for thetestOnAcquire
configuration attribute.static boolean
DEFAULT_TEST_ON_CREATE
The default value for thetestOnCreate
configuration attribute.static boolean
DEFAULT_TEST_ON_RELEASE
The default value for thetestOnRelease
configuration attribute.
-
Constructor Summary
Constructors Modifier Constructor Description protected
BasePoolConfig(boolean testOnCreate, boolean testOnAcquire, boolean testOnRelease)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isTestOnAcquire()
Get the value for thetestOnAcquire
configuration attribute for pools created with this configuration instance.boolean
isTestOnCreate()
Get the value for thetestOnCreate
configuration attribute for pools created with this configuration instance.boolean
isTestOnRelease()
Get the value for thetestOnRelease
configuration attribute for pools created with this configuration instance.
-
-
-
Field Detail
-
DEFAULT_TEST_ON_CREATE
public static final boolean DEFAULT_TEST_ON_CREATE
The default value for thetestOnCreate
configuration attribute.- See Also:
- Constant Field Values
-
DEFAULT_TEST_ON_ACQUIRE
public static final boolean DEFAULT_TEST_ON_ACQUIRE
The default value for thetestOnAcquire
configuration attribute.- See Also:
- Constant Field Values
-
DEFAULT_TEST_ON_RELEASE
public static final boolean DEFAULT_TEST_ON_RELEASE
The default value for thetestOnRelease
configuration attribute.- See Also:
- Constant Field Values
-
-
Method Detail
-
isTestOnCreate
public boolean isTestOnCreate()
Get the value for thetestOnCreate
configuration attribute for pools created with this configuration instance.- Returns:
- the current setting of
testOnCreate
for this configuration instance.
-
isTestOnAcquire
public boolean isTestOnAcquire()
Get the value for thetestOnAcquire
configuration attribute for pools created with this configuration instance.- Returns:
- the current setting of
testOnAcquire
for this configuration instance.
-
isTestOnRelease
public boolean isTestOnRelease()
Get the value for thetestOnRelease
configuration attribute for pools created with this configuration instance.- Returns:
- the current setting of
testOnRelease
for this configuration instance.
-
-