|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.ibm.websphere.rsadapter.GenericDataStoreHelper com.ca.idms.was.IdmsJdbcDataStoreHelper
public class IdmsJdbcDataStoreHelper
WebSphere DataStoreHelper Class for CA IDMS.
WebSphere Application Server 5.0, and later, includes a Relational
Resource Adapter. This is a JCA-compliant interface used for JDBC
access by J2EE 1.3-compliant applications. The Relational Resource
Adapter uses a DataStoreHelper
class at runtime to
determine the characteristics of a database or other source of data
and optimize code generated for EJBs using container managed persistence.
DataStoreHelper
is an interface. IBM supplies an
implementation class for each “supported” datastore provider, and a
GenericDataStoreHelper
class for “unsupported” providers.
This class extends GenericDataStoreHelper
as permitted by
IBM to provide the data source-specific support for CA IDMS.
Clients may write their own helper classes which extend this class.
Then they may either code methods which are present in
GenericDataStoreHelper
but not referenced here, or
override methods which are referenced here.
This version of the WebSphere DataStoreHelper Class for CA IDMS
is for WebSphere version 7 or later.
This helper class contains a number of trace points which are helpful for debugging
and can be activated by setting property trace=true
in the
caidms.properties file. The trace records will be written to the file specified
by trace.file
. See the CA IDMS Server Javadoc for the TraceObject
class for more detailed information about tracing.
The following WebSphere jar files must be in the classpath to compile or run this class:
Field Summary |
---|
Fields inherited from class com.ibm.websphere.rsadapter.GenericDataStoreHelper |
---|
customDefinedWasDefaultIsoLevel, EOLN, genErrorMap, resBundle |
Fields inherited from interface com.ibm.websphere.rsadapter.DataStoreHelper |
---|
CLOUDSCAPE_HELPER, CLOUDSCAPE_NETWORK_SERVER_HELPER, CONNECTJDBC_HELPER, CUSTOM_HELPER, DATADIRECT_HELPER, DB2_390_HELPER, DB2_390_LOCAL_HELPER, DB2_400_HELPER, DB2_HELPER, DB2_UNIVERSAL_HELPER, DERBY_HELPER, DERBY_NETWORK_SERVER_HELPER, FIRST_TIME_CALLED, GENERIC_HELPER, INFORMIX_HELPER, INFORMIX_JCC_HELPER, MSSQL_HELPER, ORACLE_10G_HELPER, ORACLE_11G_HELPER, ORACLE_HELPER, POTENTIAL_DEADLOCK, POTENTIAL_LOST_UPDATE, PROXY_DS_HELPER, SEQUELINK_HELPER, SYBASE_HELPER, SYBASE11_HELPER, TX_REPEATABLE_READ_FORUPDATE, TX_SERIALIZABLE_FORUPDATE, UNDEFINED_HELPER, UNDEFINED_ISOLATOIN_LEVEL, UPDATE_ON_READONLY |
Constructor Summary | |
---|---|
IdmsJdbcDataStoreHelper(java.util.Properties props)
Creates an instance of the CA IDMS Helper Class. |
Method Summary | |
---|---|
boolean |
doConnectionCleanup(java.sql.Connection conn)
Called by WebSphere whenever a connection is released by the application and placed back into the connection pool. |
boolean |
doConnectionCleanupPerCloseConnection(java.sql.Connection conn,
boolean isCMP,
java.lang.Object props)
Called by WebSphere immediately after a connection handle is closed by the application, or implicitly by WebSphere run-time. |
void |
doConnectionSetup(java.sql.Connection conn)
Called by WebSphere whenever a new connection to the data source is created. |
boolean |
doConnectionSetupPerGetConnection(java.sql.Connection conn,
boolean isCMP,
java.lang.Object props)
Called by WebSphere before a connection handle is provided to the application. |
void |
doStatementCleanup(java.sql.PreparedStatement stmt)
Called by WebSphere if certain statement properties, like cursor name, have been changed prior to placing the statement object into a cache. |
java.lang.String |
getXAExceptionContents(javax.transaction.xa.XAException xae)
This method provides additional information for an XAException. |
boolean |
isConnectionError(java.sql.SQLException ex)
Called by WebSphere to determine whether a particular SQLException constitutes a connection error. |
Methods inherited from class com.ibm.websphere.rsadapter.GenericDataStoreHelper |
---|
calcPartitionNumber, doConnectionSetupPerTransaction, findMappingClass, getIsolationLevel, getLockType, getMetaData, getPasswordForUseWithTrustedContextWithAuthentication, getPrintWriter, getResultSetConcurrency, getResultSetType, hasLostUpdateOrDeadLockOccurred, isBatchUpdateSupportedWithAccessIntent, isDuplicateKey, mapException, modifyXAFlag, setUserDefinedMap, showLockInfo |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public IdmsJdbcDataStoreHelper(java.util.Properties props)
Only SQLState values need to be mapped for CA IDMS. The pertinent ones are:
GenericDataStoreHelper
class. This class provides mapping for all
of the others.
Clients may override these mappings or provide additional mappings
in their own helper classes as shown below:
java.util.Map xMap = new java.util.HashMap();
// for SQLCodes:
xMap.put(new Integer(nnnn), StaleConnectionException.class);
// for SQLStates:
xMap.put("nnnnn",DuplicateKeyException.class);
setUserDefinedMap(xMap);
props
- - DataStoreHelper
properties passed from WebSphere. These
properties are for future extensibility and are not currently used.Method Detail |
---|
public boolean doConnectionCleanup(java.sql.Connection conn) throws java.sql.SQLException
doConnectionCleanup
in interface com.ibm.websphere.rsadapter.DataStoreHelper
doConnectionCleanup
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
java.sql.SQLException
public boolean doConnectionCleanupPerCloseConnection(java.sql.Connection conn, boolean isCMP, java.lang.Object props) throws java.sql.SQLException
doConnectionCleanupPerCloseConnection
in interface com.ibm.websphere.rsadapter.DataStoreHelper
doConnectionCleanupPerCloseConnection
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
java.sql.SQLException
public void doConnectionSetup(java.sql.Connection conn) throws java.sql.SQLException
doConnectionSetup
in interface com.ibm.websphere.rsadapter.DataStoreHelper
doConnectionSetup
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
java.sql.SQLException
public boolean doConnectionSetupPerGetConnection(java.sql.Connection conn, boolean isCMP, java.lang.Object props) throws java.sql.SQLException
doConnectionSetupPerGetConnection
in interface com.ibm.websphere.rsadapter.DataStoreHelper
doConnectionSetupPerGetConnection
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
java.sql.SQLException
public void doStatementCleanup(java.sql.PreparedStatement stmt) throws java.sql.SQLException
doStatementCleanup
in interface com.ibm.websphere.rsadapter.DataStoreHelper
doStatementCleanup
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
java.sql.SQLException
public boolean isConnectionError(java.sql.SQLException ex)
true
.
isConnectionError
in interface com.ibm.websphere.rsadapter.DataStoreHelper
isConnectionError
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
public java.lang.String getXAExceptionContents(javax.transaction.xa.XAException xae)
getXAExceptionContents
in interface com.ibm.websphere.rsadapter.DataStoreHelper
getXAExceptionContents
in class com.ibm.websphere.rsadapter.GenericDataStoreHelper
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |