public abstract class ApiProxyPool extends Object implements ApiProxyPoolI
ProxyManager#adjustConnectionVariables
. Using
a value of 0 effectively disables idle proxies from ever terminating prior
to shut down.
Constructor and Description |
---|
ApiProxyPool(String name,
int maxProxiesPerServer) |
ApiProxyPool(String name,
int idleConnectionSize,
int maximumPoolSize,
long connectionTimeout,
ARTimeUnit unit) |
Modifier and Type | Method and Description |
---|---|
void |
adjustPoolParameters(int maximumPoolSize,
int idleConnectionsPerServer)
Set pool parameters and dynamically adjust the pool accordingly
|
void |
ageOutIdleProxy()
Proxies, which have no activities, are aged out.
|
void |
clear()
Clear this pool
|
void |
deRecodeProxy(ApiProxyI t) |
boolean |
equals(Object obj) |
ApiProxyI |
get(ApiUserContextI context)
Return a proxy from the pool.
|
long |
getEstablishTime()
get the system time this pool is established
|
int |
getLargestPoolSize()
Returns the largest number of proxies that have ever
simultaneously been in the pool.
|
long |
getLastUsed()
get the system time this pool was used
|
String |
getPoolName()
get the pool name
|
int |
hashCode() |
void |
put(ApiProxyI proxy)
Return a proxy to the pool.
|
void |
setEstablishTime(long m_establishTime)
set the system time this pool is established
|
void |
setLastUsed(long tm)
set the system time this pool was used
|
String |
toString() |
public ApiProxyPool(String name, int idleConnectionSize, int maximumPoolSize, long connectionTimeout, ARTimeUnit unit)
public ApiProxyPool(String name, int maxProxiesPerServer)
public void setLastUsed(long tm)
ApiProxyPoolI
setLastUsed
in interface ApiProxyPoolI
public long getLastUsed()
ApiProxyPoolI
getLastUsed
in interface ApiProxyPoolI
public void deRecodeProxy(ApiProxyI t)
public ApiProxyI get(ApiUserContextI context) throws ARException
get
in interface ApiProxyPoolI
InterruptedException
ARException
public void put(ApiProxyI proxy)
put
in interface ApiProxyPoolI
public void ageOutIdleProxy()
public void adjustPoolParameters(int maximumPoolSize, int idleConnectionsPerServer)
maximumPoolSize
- idleConnectionsPerServer
- public String getPoolName()
ApiProxyPoolI
getPoolName
in interface ApiProxyPoolI
public int getLargestPoolSize()
public void clear()
ApiProxyPoolI
clear
in interface ApiProxyPoolI
public void setEstablishTime(long m_establishTime)
establishTime
- public long getEstablishTime()
getEstablishTime
in interface ApiProxyPoolI
? Copyright 2013 BMC Software, Inc.