Package org.apache.geode.cache.client
Class PoolManager
java.lang.Object
org.apache.geode.cache.client.PoolManager
Manages creation and access to
connection pools for clients.
To create a pool get a factory by calling createFactory().
To find an existing pool by name call find(String).
To get rid of all created pool call close().
- Since:
- GemFire 5.7
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidclose()Unconditionally destroys all created pools that are in this manager.static voidclose(boolean keepAlive) Unconditionally destroys all created pools that are in this manager.static PoolFactoryCreates a newpool factory, which is used to configure and create newPools.static PoolFind by name an existing connection pool returning the existing pool ornullif it does not exist.static PoolFind the pool used by the given region.getAll()Returns a map containing all the pools in this manager.
-
Method Details
-
createFactory
Creates a newpool factory, which is used to configure and create newPools.- Returns:
- the new pool factory
-
find
Find by name an existing connection pool returning the existing pool ornullif it does not exist.- Parameters:
name- the name of the connection pool- Returns:
- the existing connection pool or
nullif it does not exist.
-
getAll
Returns a map containing all the pools in this manager. The keys are pool names and the values arePoolinstances.The map contains the pools that this manager knows of at the time of this call. The map is free to be changed without affecting this manager.
- Returns:
- a Map that is a snapshot of all the pools currently known to this manager.
-
close
public static void close(boolean keepAlive) Unconditionally destroys all created pools that are in this manager.- Parameters:
keepAlive- whether the server should keep the durable client's subscriptions alive for thedurable-client-timeout.- See Also:
-
find
Find the pool used by the given region.- Parameters:
region- The region that is using the pool.- Returns:
- the pool used by that region or
nullif the region does not have a pool.
-
close
public static void close()Unconditionally destroys all created pools that are in this manager.
-