Wednesday, December 07, 2011

Configure IBM InfoSphere Classic JDBC Driver datasource in WebSphere

To setup the InfoSphere Classic JDBC Data source in WebSphere, you could follow the following steps:
1. Create new JDBC Provider
1.1 Resources->JDBC->JDBC providers->new
1.2 Database type: User-defined; Implementation class name: com.cac.jdbc.ConnectionPoolDataSource; Name: IBM InfoSphere Classic JDBC
1.3 Class path: ${User-defined_JDBC_DRIVER_PATH}/DataFederationServer/cacjdbc21.jar
1.4 Review summary->Finish->save
2. Create Java 2 Connector authentication data entry
2.1 Security->Global security; Under Authentication cache settings, click Java Authentication And Authorization Service->J2C authnetication data; new
2.2 Alias: ; UserID: ; Password: ; Apply-> save
3. Create new Data Source
3.1 Resources->JDBC->Data sources; new
3.2 Data source name: DFS_XXXX; JNDI name: jdbc/DFS_ADABAS
3.3 Select the JDBC provider created in step 1.
3.4 Data store helper class name: com.ibm.websphere.rsadapter.GenericDataStoreHelper; Uncheck used for CMP check box.
3.5 Component-managed authentication alias: the one you created in step 2.

3.6 Review summary->Finish->save
3.7 setup the Custom properties for the newly create Data source by click on the Data source name -> Customer properties
3.7.1 URL: your Data Federation Server JDBC URL;
3.7.2
webSphereDefaultIsolationLevel: 1 (READ_UNCOMMITED); very tricky, I can only make it work by setting to 1. It turns out the backend (ADABAS) is set to support READ_UNCOMMITED.
3.8 If you run into "JDBC hung when try to close connection" in your application, try to turn off the statement cache; Search IBM fix pack change list for similar problem for Oracle, and Sybase JDBC connection.
You almost done, just restart your web sphere server and start to use the JDBC Data source.

No comments: