Module.xml file for csjdbc.jar file - Teiid connection with Composite Driver
sarvesh723 Oct 27, 2014 2:41 PMIn TEIID Designer, I am trying to connect to Composite software data source using csjdbc.jar file for the driver cs.jdbc.driver.CompositeDriver by using Generic JDBC Connection. The connection URL which I am passing in TEIID designer along with the csjdbc.jar file and cs.jdbc.driver.CompositeDriver driver is working fine and I can import the tables from Composite data source in TEIID as a source. The same connection URL works fine in SQUIRELL sql client and I can run queries on that source to retrive data. However, when I try to deploy the VDB file and then run an ODATA query in the browser on that source I get the following error:
JBWEB000065: HTTP Status 500 -
--------------------------------------------------------------------------------
JBWEB000309: type JBWEB000066: Exception report
JBWEB000068: message
JBWEB000069: description JBWEB000145: The server encountered an internal error that prevented it from fulfilling this request.
JBWEB000070: exception
Exception [EclipseLink-4002] (Eclipse Persistence Services - 2.4.1.v20121003-ad44345): org.eclipse.persistence.exceptions.DatabaseException
Internal Exception: org.teiid.jdbc.TeiidSQLException: TEIID30504 SISORSrc: 1947005 TEIID11008:TEIID11004 Error executing statement(s): [Prepared Values: [] SQL: SELECT "WIDAT"."WIDAT"."AREA"."AREA_ID", "WIDAT"."WIDAT"."AREA"."AREA_TYPE", "WIDAT"."WIDAT"."AREA"."PPDM_GUID", "WIDAT"."WIDAT"."AREA"."PREFERRED_NAME", "WIDAT"."WIDAT"."AREA"."REMARK" FROM "WIDAT"."WIDAT"."AREA"]
Error Code: 1947005
Call: SELECT "AREA_ID", "AREA_TYPE", "PPDM_GUID", "PREFERRED_NAME", "REMARK" FROM "PDMSPView.AREA_TEST_SISOR"
Query: ReadAllQuery(referenceClass=AREA_TEST_SISOR sql="SELECT "AREA_ID", "AREA_TYPE", "PPDM_GUID", "PREFERRED_NAME", "REMARK" FROM "PDMSPView.AREA_TEST_SISOR"")
The SQL statement is working fine on the source when tested in SQUIRELL client. However, the ODATA is showing error.
I did the same sceario with a data source from SQL Server using sqljdbc4.jar file and tried to produce the same error in ODATA. I noticed that for sql server there is a module.xml file in the same folder as the sqljdbc4.jar file which has the below contents: If I delete any line from the dependencies tag then I get same error in ODATA as I get while running the VDB containing Composite data source connection. I have created the module.xml file for csjdbc.jar file in the same way as there was for sqljdbc4.jar file but the error is not resolved. For the csjdbc.jar file what dependencies should I provide in the dependencies tag in module.xml file and where can I find this information?
The SQL Server module.xml file is as follows (This works fine without any errors)
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.1" name="com.microsoft.sqlserver">
<resources>
<resource-root path="sqljdbc4.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
The composite module.xml file is as follows
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.1" name="com.composite.jdbc">
<resources>
<resource-root path="csjdbc.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
NOTE: All the fjar files, and module files are in correct location and the standalone file has the correct connection URL and drivers specified.