public abstract class CorbaConnectionCacheBase extends Object implements ConnectionCache, CorbaConnectionCache
Modifier and Type | Field and Description |
---|---|
protected String |
cacheType |
protected String |
monitoringName |
protected ORB |
orb |
protected long |
timestamp |
protected ORBUtilSystemException |
wrapper |
Modifier | Constructor and Description |
---|---|
protected |
CorbaConnectionCacheBase(ORB orb,
String cacheType,
String monitoringName) |
Modifier and Type | Method and Description |
---|---|
protected abstract Object |
backingStore() |
void |
close()
Close all connections in the connection cache.
|
protected void |
dprint(String msg) |
protected void |
dprintCreation() |
protected void |
dprintStatistics() |
String |
getCacheType() |
String |
getMonitoringName() |
long |
numberOfBusyConnections() |
long |
numberOfConnections() |
long |
numberOfIdleConnections() |
boolean |
reclaim()
Discarding least recently used Connections that are not busy
This method must be synchronized since one WorkerThread could
be reclaming connections inside the synchronized backingStore
block and a second WorkerThread (or a SelectorThread) could have
already executed the if (numberOfConnections <= ....
|
protected abstract void |
registerWithMonitoring() |
void |
stampTime(Connection c) |
abstract Collection |
values() |
protected ORB orb
protected long timestamp
protected String cacheType
protected String monitoringName
protected ORBUtilSystemException wrapper
public String getCacheType()
getCacheType
in interface ConnectionCache
public void stampTime(Connection c)
stampTime
in interface ConnectionCache
public long numberOfConnections()
numberOfConnections
in interface ConnectionCache
public void close()
ConnectionCache
close
in interface ConnectionCache
public long numberOfIdleConnections()
numberOfIdleConnections
in interface ConnectionCache
public long numberOfBusyConnections()
numberOfBusyConnections
in interface ConnectionCache
public boolean reclaim()
reclaim
in interface ConnectionCache
public String getMonitoringName()
getMonitoringName
in interface CorbaConnectionCache
public abstract Collection values()
protected abstract Object backingStore()
protected abstract void registerWithMonitoring()
protected void dprintCreation()
protected void dprintStatistics()
protected void dprint(String msg)
Copyright © 2018 JBoss by Red Hat. All rights reserved.