|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.sap.mw.jco.JCO.Pool
This class encapsulates a connection pool. A pool is a set of client-connections to a certain destination. The pool may automatically create new connections to the specified remote system or return an already existing one. It also provides methods to return a connection back to the pool when it is no longer needed.
Method Summary | |
boolean |
getAbapDebug()
Returns true if ABAP debugging is enabled for the connections of this pool, and false otherwise. |
int |
getCurrentPoolSize()
Returns the current pool size, i.e. the number of connections which are opened and internally helt by the pool. |
int |
getMaxPoolSize()
Returns the max. pool size |
int |
getMaxUsed()
Returns the max. number of connections used so far |
long |
getMaxWaitTime()
Returns the max. time to wait for a connection request when the pool is exhausted. |
java.lang.String |
getName()
Returns the pool's name |
int |
getNumUsed()
Returns the number of connections in the pool which are currently reserved by the application due to calls to JCO.getClient(). |
int |
getNumWaitingThreads()
Returns the number of threads that are waiting for a connection. |
JCO.PoolManager |
getPoolManager()
Returns the pool manager this pool is a member of |
boolean |
getResetOnRelease()
Returns true if a connection is being cleaned up in JCO.releaseClient(), false otherwise. |
byte[] |
getStates()
Returns the states of all existing client connections in this pool |
boolean |
getTrace()
Returns whether trace for this pool is enabled or not. |
void |
setAbapDebug(boolean debug)
Enables/disables ABAP debug |
void |
setMaxWaitTime(long max_wait_time)
Sets the max. time to wait in a connection request when the pool is exhausted. |
void |
setResetOnRelease(boolean reset_on_release)
Enables/disables cleanup when the client is being returned to its pool. |
void |
setTrace(boolean trace)
Enables/disables trace for the connections of the pool. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public final void setResetOnRelease(boolean reset_on_release)
reset_on_release
- if true reset the connection, e.g. free all resources
that might have been allocated on either the server side or by the local
middleware layer. On systems below SAP 4.0A resetting a connection
effectively means closing and subsequently reopening the connection
which is a very expensive process. However, several scenarios
(e.g. BAPIs) need reinitialized connections while others might not.
This depends strongly on the function modules and their implementation
in the mySAP system. In certain cases it might be worthwhile to switch
the cleanup off for performance reasons. Use with care !public final boolean getResetOnRelease()
public void setAbapDebug(boolean debug)
debug
- if true enables ABAP debugging, disables it otherwisepublic final boolean getAbapDebug()
public final boolean getTrace()
public final void setTrace(boolean trace)
trace
- if true enables the trace and disables it otherwise.public final java.lang.String getName()
public final JCO.PoolManager getPoolManager()
public final int getMaxPoolSize()
public final int getCurrentPoolSize()
public final int getMaxUsed()
public final int getNumUsed()
public final int getNumWaitingThreads()
public final void setMaxWaitTime(long max_wait_time)
max_wait_time
- the time to wait for a connection request in millisecondspublic final long getMaxWaitTime()
public final byte[] getStates()
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |