Oracle10g JDBC

oracle.jdbc.pool
Class OracleConnectionCacheImpl

java.lang.Object
  extended byoracle.jdbc.pool.OracleDataSource
      extended byoracle.jdbc.pool.OracleConnectionCacheImpl
All Implemented Interfaces:
javax.sql.DataSource, OracleConnectionCache, javax.naming.Referenceable, java.io.Serializable
Direct Known Subclasses:
OracleXAConnectionCacheImpl

Deprecated. ... Use JDBC Implicit Connection Caching instead

public class OracleConnectionCacheImpl
extends OracleDataSource
implements OracleConnectionCache, java.io.Serializable, javax.naming.Referenceable

See Also:
Serialized Form

Field Summary
static java.lang.String BUILD_DATE
          Deprecated.  
static long DEFAULT_FIXED_WAIT_IDLE_TIME
          Deprecated. The default timeout for FIXED_WAIT_SCHEME.
static int DYNAMIC_SCHEME
          Deprecated.  
static int FIXED_RETURN_NULL_SCHEME
          Deprecated.  
static int FIXED_WAIT_SCHEME
          Deprecated.  
static int ORAERROR_END_OF_FILE_ON_COM_CHANNEL
          Deprecated.  
static int ORAERROR_IMMEDIATE_SHUTDOWN_IN_PROGRESS
          Deprecated.  
static int ORAERROR_INIT_SHUTDOWN_IN_PROGRESS
          Deprecated.  
static int ORAERROR_NET_IO_EXCEPTION
          Deprecated.  
static int ORAERROR_NOT_CONNECTED_TO_ORACLE
          Deprecated.  
static int ORAERROR_ORACLE_NOT_AVAILABLE
          Deprecated.  
static int ORAERROR_SHUTDOWN_IN_PROGRESS_NO_CONN
          Deprecated.  
static boolean PRIVATE_TRACE
          Deprecated.  
static boolean TRACE
          Deprecated.  
 
Fields inherited from class oracle.jdbc.pool.OracleDataSource
isOracleDataSource
 
Constructor Summary
OracleConnectionCacheImpl()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Default Constructor. Should have an explicit call to set the URL, User, Password and other DataSource details. A ConnectionPoolDataSource is created with these options from which PooledConnections can be created.

OracleConnectionCacheImpl(javax.sql.ConnectionPoolDataSource ds)
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Create an OracleConnectionCacheImpl with the given ConnectionPoolDataSource from which PooledConnections have to created. In which case, url, user name, password, and other DataSource properties set on this Cache are ignored.

 
Method Summary
 void clearWarnings()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Clear SQLWarning. Sets SQLWarning to null.

 void close()
          Deprecated. Close the connection cache.
 void closeConnections()
          Deprecated.  
 void closePooledConnection(javax.sql.PooledConnection pc)
          Deprecated.  Invoked by the ConnectionEventListener when an error occurs on a PooledConnection/LogicalConnection signaling that it is no longer good to be used and can be closed.
 void closeSingleConnection(javax.sql.PooledConnection pc)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Close and remove a PooledConnection in the cache
 int getActiveSize()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the total no of connections that are being used.
 long getCacheFixedWaitIdleTime()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Returns the wait time for FIXED_WAIT_SCHEME. Returns -1 if it is not set.
 long getCacheFixedWaitTimeout()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the timeout for FIXED_WAIT_SCHEME

 long getCacheInactivityTimeout()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the connection cache Inactivity timeout

 int getCacheScheme()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the Caching Scheme being used.
 int getCacheSize()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the total no of connections in the Cache.
 long getCacheTimeToLiveTimeout()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the connection cache TTL timeout

 java.sql.Connection getConnection()
          Deprecated. Attempt to establish a database connection.
 java.sql.Connection getConnection(java.lang.String user, java.lang.String passwd)
          Deprecated. Attempt to establish a database connection.
 long getConnectionCleanupInterval()
          Deprecated.  
 int[] getConnectionErrorCodes()
          Deprecated.  
 int getMaxLimit()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the Max limit on Connections.

 int getMinLimit()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the minimum limit on the no of Connections.
 javax.naming.Reference getReference()
          Deprecated.  
 int getStmtCacheSize()
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the size of Statement Cache.
 long getThreadWakeUpInterval()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the timeout thread interval

 java.sql.SQLWarning getWarnings()
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Return current SQLWarning

 boolean isFatalConnectionError(java.sql.SQLException se)
          Deprecated.  
 void reusePooledConnection(javax.sql.PooledConnection pc)
          Deprecated.  Invoked by the ConnectionEventListener instance when Logical connection handles are closed signaling that the PooledConnection can be recycled into the pool for further use.
 void setCacheFixedWaitIdleTime(long idleTime)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Waiting time for the FIXED_WAIT_SCHEME. This is the time in seconds for which the Connection cache would wait before returning with an exception.
 void setCacheFixedWaitTimeout(long timeout)
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set timeout for the FIXED_WAIT_SCHEME

 void setCacheInactivityTimeout(long timeout)
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the Inactivity timeout for this connection cache

 void setCacheScheme(int s)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Scheme for this Cache. Possible values are OracleConnectionCacheImpl.DYNAMIC_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_NULL_SCHEME OracleConnectionCacheImpl.FIXED_WAIT_SCHEME
 void setCacheScheme(java.lang.String s)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Scheme for this Cache. Possible values are OracleConnectionCacheImpl.DYNAMIC_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_NULL_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_SCHEME
 void setCacheTimeToLiveTimeout(long timeOut)
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the TTL timeout for this connection cache

 void setConnectionCleanupInterval(long secs)
          Deprecated.  
 void setConnectionErrorCodes(int[] fatalErrorCodes)
          Deprecated.  
 void setConnectionPoolDataSource(javax.sql.ConnectionPoolDataSource ds)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Associate a ConnectionPoolDataSource datasource to the Cache. If one already exists and Connections are already opened then an Exception is thrown. If no connections are opened, then the new ConnectionPoolDataSource overwrites the previous one.
 void setMaxLimit(int l)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the maximum no of connections for the Cache.
 void setMinLimit(int l)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the minimum no of connections for the Cache.
 void setStmtCacheSize(int size)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the statement cache size. Default is 0. You cannot set this for logicalhandles obtained from PooledConnections.

If more than size cursors are already cached than they will be closed. By default the meta data of the cursor will be saved. Only data and the state will be cleared. You need to call this first to enable either type of Statement caching. When both types of Statement caching are enabled, the size is the total number of cursors cached for both the schemes together.

 void setStmtCacheSize(int size, boolean clearMetaData)
          Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the statement cache size. Default is 0. You cannot set this for logicalhandles obtained from PooledConnections.

If more than size cursors are already cached than they will be closed. By default, the meta data of the cursor will be saved. But if clearMetaData is set to true, even that will be cleared. You need to call this first to enable either type of Statement caching. When both types of Statement caching are enabled, the size is the total number of cursors cached for both the schemes together.

 void setThreadWakeUpInterval(long interval)
          Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the interval for connection cache timeout thread

 
Methods inherited from class oracle.jdbc.pool.OracleDataSource
getConnection, getConnection, getConnectionCacheName, getConnectionCacheProperties, getConnectionCachingEnabled, getConnectionProperties, getDatabaseName, getDataSourceName, getDescription, getDriverType, getExplicitCachingEnabled, getFastConnectionFailoverEnabled, getImplicitCachingEnabled, getLoginTimeout, getLogWriter, getMaxStatements, getNetworkProtocol, getPortNumber, getServerName, getServiceName, getTNSEntryName, getURL, getUser, setConnectionCacheName, setConnectionCacheProperties, setConnectionCachingEnabled, setConnectionProperties, setDatabaseName, setDataSourceName, setDescription, setDriverType, setExplicitCachingEnabled, setFastConnectionFailoverEnabled, setImplicitCachingEnabled, setLoginTimeout, setLogWriter, setMaxStatements, setNetworkProtocol, setPassword, setPortNumber, setServerName, setServiceName, setTNSEntryName, setURL, setUser
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.sql.DataSource
getLoginTimeout, getLogWriter, setLoginTimeout, setLogWriter
 

Field Detail

ORAERROR_END_OF_FILE_ON_COM_CHANNEL

public static final int ORAERROR_END_OF_FILE_ON_COM_CHANNEL
Deprecated. 
See Also:
Constant Field Values

ORAERROR_NOT_CONNECTED_TO_ORACLE

public static final int ORAERROR_NOT_CONNECTED_TO_ORACLE
Deprecated. 
See Also:
Constant Field Values

ORAERROR_INIT_SHUTDOWN_IN_PROGRESS

public static final int ORAERROR_INIT_SHUTDOWN_IN_PROGRESS
Deprecated. 
See Also:
Constant Field Values

ORAERROR_ORACLE_NOT_AVAILABLE

public static final int ORAERROR_ORACLE_NOT_AVAILABLE
Deprecated. 
See Also:
Constant Field Values

ORAERROR_IMMEDIATE_SHUTDOWN_IN_PROGRESS

public static final int ORAERROR_IMMEDIATE_SHUTDOWN_IN_PROGRESS
Deprecated. 
See Also:
Constant Field Values

ORAERROR_SHUTDOWN_IN_PROGRESS_NO_CONN

public static final int ORAERROR_SHUTDOWN_IN_PROGRESS_NO_CONN
Deprecated. 
See Also:
Constant Field Values

ORAERROR_NET_IO_EXCEPTION

public static final int ORAERROR_NET_IO_EXCEPTION
Deprecated. 
See Also:
Constant Field Values

DEFAULT_FIXED_WAIT_IDLE_TIME

public static final long DEFAULT_FIXED_WAIT_IDLE_TIME
Deprecated. 
The default timeout for FIXED_WAIT_SCHEME. This is the number of seconds up to which the thread would wait before returning in FIXED_WAIT_SCHEME.

See Also:
Constant Field Values

DYNAMIC_SCHEME

public static final int DYNAMIC_SCHEME
Deprecated. 
See Also:
Constant Field Values

FIXED_WAIT_SCHEME

public static final int FIXED_WAIT_SCHEME
Deprecated. 
See Also:
Constant Field Values

FIXED_RETURN_NULL_SCHEME

public static final int FIXED_RETURN_NULL_SCHEME
Deprecated. 
See Also:
Constant Field Values

TRACE

public static final boolean TRACE
Deprecated. 
See Also:
Constant Field Values

PRIVATE_TRACE

public static final boolean PRIVATE_TRACE
Deprecated. 
See Also:
Constant Field Values

BUILD_DATE

public static final java.lang.String BUILD_DATE
Deprecated. 
See Also:
Constant Field Values
Constructor Detail

OracleConnectionCacheImpl

public OracleConnectionCacheImpl()
                          throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Default Constructor. Should have an explicit call to set the URL, User, Password and other DataSource details. A ConnectionPoolDataSource is created with these options from which PooledConnections can be created.

Throws:
java.sql.SQLException - error creating Cache

OracleConnectionCacheImpl

public OracleConnectionCacheImpl(javax.sql.ConnectionPoolDataSource ds)
                          throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Create an OracleConnectionCacheImpl with the given ConnectionPoolDataSource from which PooledConnections have to created. In which case, url, user name, password, and other DataSource properties set on this Cache are ignored.

Parameters:
ds - a datasource from which the Cache can create PooledConnections.
Throws:
java.sql.SQLException - error creating Cache
Method Detail

setConnectionPoolDataSource

public void setConnectionPoolDataSource(javax.sql.ConnectionPoolDataSource ds)
                                 throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Associate a ConnectionPoolDataSource datasource to the Cache. If one already exists and Connections are already opened then an Exception is thrown. If no connections are opened, then the new ConnectionPoolDataSource overwrites the previous one.

Parameters:
ds - a datasource from which the Cache can create PooledConnections.
Throws:
java.sql.SQLException - A ConnectionPoolDataSource object already exists and connections are already open.

getConnection

public java.sql.Connection getConnection()
                                  throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Attempt to get a logical connection from the Cache. May return null depending upon the Schemes selected. Either a ConnectionPoolDataSource must be Set or url, username, password or Other JNDI attributes should be set on this Cache before you attempt to open Connections.

Description copied from class: OracleDataSource

Attempt to establish a database connection.

Specified by:
getConnection in interface javax.sql.DataSource
Overrides:
getConnection in class OracleDataSource
Returns:
Connection A logical Connection Object.
Throws:
java.sql.SQLException - error creating Connection Object.

getConnection

public java.sql.Connection getConnection(java.lang.String user,
                                         java.lang.String passwd)
                                  throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Attempt to get a logical connection from the Cache. May return null depending upon the Schemes selected. User and password arguments should match the one given either directly or from ConnectionPoolDataSource.

Description copied from class: OracleDataSource

Attempt to establish a database connection.

Specified by:
getConnection in interface javax.sql.DataSource
Overrides:
getConnection in class OracleDataSource
Parameters:
user - the database user on whose behalf the Connection is being made
Returns:
Connection A logical Connection Object.
Throws:
java.sql.SQLException - error creating Connection Object.

reusePooledConnection

public void reusePooledConnection(javax.sql.PooledConnection pc)
                           throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Invoked by the ConnectionEventListener instance when Logical connection handles are closed signaling that the PooledConnection can be recycled into the pool for further use.

Description copied from interface: OracleConnectionCache

Invoked by the ConnectionEventListener instance when Logical connection handles are closed signaling that the PooledConnection can be recycled into the pool for further use.

Specified by:
reusePooledConnection in interface OracleConnectionCache
Parameters:
pc - The pooled connection object that needs to be recylced.
Throws:
java.sql.SQLException - error in recycling the PooledConnection.

closePooledConnection

public void closePooledConnection(javax.sql.PooledConnection pc)
                           throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Invoked by the ConnectionEventListener when an error occurs on a PooledConnection/LogicalConnection signaling that it is no longer good to be used and can be closed.

Description copied from interface: OracleConnectionCache

Invoked by the ConnectionEventListener when an error occurs on a PooledConnection/LogicalConnection signaling that it is no longer good to be used and can be closed.

Specified by:
closePooledConnection in interface OracleConnectionCache
Parameters:
pc - The pooled connection object that has to be closed because of an error.
Throws:
java.sql.SQLException - error in closing the PooledConnection

closeSingleConnection

public void closeSingleConnection(javax.sql.PooledConnection pc)
                           throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Close and remove a PooledConnection in the cache

Throws:
java.sql.SQLException

close

public void close()
           throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Physically close all the pooled connections in the cache and free all the resources.

Description copied from interface: OracleConnectionCache
Close the connection cache. All the pooled connections have to be closed.

Specified by:
close in interface OracleConnectionCache
Overrides:
close in class OracleDataSource
Throws:
java.sql.SQLException - error in closing the PooledConnection

closeConnections

public void closeConnections()
Deprecated. 

setConnectionCleanupInterval

public void setConnectionCleanupInterval(long secs)
                                  throws java.sql.SQLException
Deprecated. 
Throws:
java.sql.SQLException

getConnectionCleanupInterval

public long getConnectionCleanupInterval()
                                  throws java.sql.SQLException
Deprecated. 
Throws:
java.sql.SQLException

setConnectionErrorCodes

public void setConnectionErrorCodes(int[] fatalErrorCodes)
                             throws java.sql.SQLException
Deprecated. 
Throws:
java.sql.SQLException

getConnectionErrorCodes

public int[] getConnectionErrorCodes()
                              throws java.sql.SQLException
Deprecated. 
Throws:
java.sql.SQLException

isFatalConnectionError

public boolean isFatalConnectionError(java.sql.SQLException se)
Deprecated. 

setMinLimit

public void setMinLimit(int l)
                 throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the minimum no of connections for the Cache.

Parameters:
l - Minimum no. of Connections.
Throws:
java.sql.SQLException

getMinLimit

public int getMinLimit()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the minimum limit on the no of Connections.

Returns:
minimum limit on the no of Connections.

setMaxLimit

public void setMaxLimit(int l)
                 throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the maximum no of connections for the Cache.

Parameters:
l - maximum no. of Connections.
Throws:
java.sql.SQLException

getMaxLimit

public int getMaxLimit()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the Max limit on Connections.

Returns:
int Max no of Connections that can be opened.

getCacheScheme

public int getCacheScheme()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the Caching Scheme being used.

Returns:
the caching scheme.

setCacheScheme

public void setCacheScheme(int s)
                    throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Scheme for this Cache. Possible values are OracleConnectionCacheImpl.DYNAMIC_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_NULL_SCHEME OracleConnectionCacheImpl.FIXED_WAIT_SCHEME

Throws:
java.sql.SQLException

setCacheScheme

public void setCacheScheme(java.lang.String s)
                    throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Scheme for this Cache. Possible values are OracleConnectionCacheImpl.DYNAMIC_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_NULL_SCHEME OracleConnectionCacheImpl.FIXED_RETURN_SCHEME

Throws:
java.sql.SQLException

getActiveSize

public int getActiveSize()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the total no of connections that are being used.

Returns:
total no of active connections.

getCacheSize

public int getCacheSize()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the total no of connections in the Cache.

Returns:
total no of connections opened.

setCacheTimeToLiveTimeout

public void setCacheTimeToLiveTimeout(long timeOut)
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the TTL timeout for this connection cache

Returns:
Throws:
java.sql.SQLException - raises SQLWarning, if an invalid timeout is specified

setCacheInactivityTimeout

public void setCacheInactivityTimeout(long timeout)
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the Inactivity timeout for this connection cache

Returns:
Throws:
java.sql.SQLException - raises SQLWarning, if an invalid timeout is specified

setCacheFixedWaitTimeout

public void setCacheFixedWaitTimeout(long timeout)
                              throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set timeout for the FIXED_WAIT_SCHEME

Returns:
Throws:
java.sql.SQLException - raises SQLWarning, if an invalid timeout is specified

getCacheTimeToLiveTimeout

public long getCacheTimeToLiveTimeout()
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the connection cache TTL timeout

Returns:
long connection cache TTL timeout
Throws:
java.sql.SQLException

getCacheInactivityTimeout

public long getCacheInactivityTimeout()
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the connection cache Inactivity timeout

Returns:
long connection cache Inactivity timeout
Throws:
java.sql.SQLException

getCacheFixedWaitTimeout

public long getCacheFixedWaitTimeout()
                              throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the timeout for FIXED_WAIT_SCHEME

Returns:
long timeout for FIXED_WAIT SCHEME
Throws:
java.sql.SQLException

setThreadWakeUpInterval

public void setThreadWakeUpInterval(long interval)
                             throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Set the interval for connection cache timeout thread

Returns:
Throws:
java.sql.SQLException - raises SQLWarning, if an invalid interval is specified

getThreadWakeUpInterval

public long getThreadWakeUpInterval()
                             throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Get the timeout thread interval

Returns:
long thread interval, in seconds
Throws:
java.sql.SQLException

getWarnings

public java.sql.SQLWarning getWarnings()
                                throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Return current SQLWarning

Returns:
SQLWarning all the warnings spooled so far
Throws:
java.sql.SQLException

clearWarnings

public void clearWarnings()
                   throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead.

Clear SQLWarning. Sets SQLWarning to null.

Returns:
Throws:
java.sql.SQLException

getReference

public javax.naming.Reference getReference()
                                    throws javax.naming.NamingException
Deprecated. 
Specified by:
getReference in interface javax.naming.Referenceable
Overrides:
getReference in class OracleDataSource
Throws:
javax.naming.NamingException

setStmtCacheSize

public void setStmtCacheSize(int size)
                      throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the statement cache size. Default is 0. You cannot set this for logicalhandles obtained from PooledConnections.

If more than size cursors are already cached than they will be closed. By default the meta data of the cursor will be saved. Only data and the state will be cleared. You need to call this first to enable either type of Statement caching. When both types of Statement caching are enabled, the size is the total number of cursors cached for both the schemes together.

Parameters:
size - Size of the Cache
Throws:
java.sql.SQLException

setStmtCacheSize

public void setStmtCacheSize(int size,
                             boolean clearMetaData)
                      throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the statement cache size. Default is 0. You cannot set this for logicalhandles obtained from PooledConnections.

If more than size cursors are already cached than they will be closed. By default, the meta data of the cursor will be saved. But if clearMetaData is set to true, even that will be cleared. You need to call this first to enable either type of Statement caching. When both types of Statement caching are enabled, the size is the total number of cursors cached for both the schemes together.

Parameters:
size - Size of the Cache
clearMetaData - Whether the state has to be cleared or not
Throws:
java.sql.SQLException

getStmtCacheSize

public int getStmtCacheSize()
Deprecated. ... Use JDBC Implicit Connection Caching instead. Return the size of Statement Cache.

Returns:
int Size of Statement Cache. If not set, the default 0 is returned.

setCacheFixedWaitIdleTime

public void setCacheFixedWaitIdleTime(long idleTime)
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Set the Waiting time for the FIXED_WAIT_SCHEME. This is the time in seconds for which the Connection cache would wait before returning with an exception.

Throws:
java.sql.SQLException

getCacheFixedWaitIdleTime

public long getCacheFixedWaitIdleTime()
                               throws java.sql.SQLException
Deprecated. ... Use JDBC Implicit Connection Caching instead. Returns the wait time for FIXED_WAIT_SCHEME. Returns -1 if it is not set.

Throws:
java.sql.SQLException

Oracle10g JDBC

Copyright © 1998,2004, Oracle. All rights reserved