|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectSharedSessionPool
public final class SharedSessionPool
A session pool
that is not closable and hence can be shared between
different applications/datastores when referenced by a JNDI context.
Constructor Summary | |
---|---|
protected |
SharedSessionPool(ISessionPool delegate)
|
Method Summary | |
---|---|
void |
close()
closes all connections in this pool. |
protected void |
finalize()
|
int |
getAvailableCount()
Returns the number of idle connections |
ArcSDEConnectionConfig |
getConfig()
|
static ISessionPool |
getInstance(ArcSDEConnectionConfig config,
ISessionPoolFactory factory)
|
int |
getInUseCount()
Number of active sessions. |
int |
getPoolSize()
returns the number of actual connections held by this connection pool. |
ISession |
getSession()
Shortcut for getSession(true) |
ISession |
getSession(boolean transactional)
Grab a session from the pool, this session is the responsibility of the calling code and must be closed after use. |
boolean |
isClosed()
Returns whether this pool is closed |
String |
toString()
|
Methods inherited from class Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
protected SharedSessionPool(ISessionPool delegate) throws IOException
IOException
Method Detail |
---|
public static ISessionPool getInstance(ArcSDEConnectionConfig config, ISessionPoolFactory factory) throws IOException
IOException
protected void finalize()
finalize
in class Object
public void close()
ISessionPool
close
in interface ISessionPool
ISessionPool.close()
public int getAvailableCount()
ISessionPool
getAvailableCount
in interface ISessionPool
ISessionPool.getAvailableCount()
public ArcSDEConnectionConfig getConfig()
getConfig
in interface ISessionPool
ISessionPool.getConfig()
public int getInUseCount()
ISessionPool
getInUseCount
in interface ISessionPool
ISessionPool.getInUseCount()
public int getPoolSize()
ISessionPool
getPoolSize
in interface ISessionPool
ISessionPool.getPoolSize()
public ISession getSession() throws IOException, UnavailableConnectionException
ISessionPool
getSession(true)
getSession
in interface ISessionPool
IOException
UnavailableConnectionException
ISessionPool.getSession()
public ISession getSession(boolean transactional) throws IOException, UnavailableConnectionException
ISessionPool
getSession
in interface ISessionPool
transactional
- whether the session is intended to be used on a transaction, so the pool may
choose to reuse or not a connection.
IOException
- If we could not get a connection
UnavailableConnectionException
- If we are out of connectionsISessionPool.getSession(boolean)
public boolean isClosed()
ISessionPool
isClosed
in interface ISessionPool
ISessionPool.isClosed()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |