TEIID - Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable...
michaelwan.plusone Aug 31, 2012 6:02 AMDear All,
I am trying to use Teiid 7.7.1 to link several MySQL database and present to the VDB users as 1 VDB. However, I couldn't get it working and I couldn't figure out what's wrong/missing. Please help.
I have already include the MySQL driver to \jboss-as\server\default\lib\mysql-connector-java-5.1.20-bin.jar
============================================================================
USER COMMAND:
SELECT * FROM ViewCRM.customers
----------------------------------------------------------------------------
OPTIMIZE:
SELECT * FROM ViewCRM.customers
----------------------------------------------------------------------------
GENERATE CANONICAL:
SELECT * FROM ViewCRM.customers
CANONICAL PLAN:
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
Source(groups=[ViewCRM.customers])
============================================================================
EXECUTING PlaceAccess
AFTER:
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
Access(groups=[ViewCRM.customers])
Source(groups=[ViewCRM.customers])
============================================================================
EXECUTING RaiseAccess
AFTER:
Access(groups=[ViewCRM.customers], props={MODEL_ID=Schema name=ViewCRM, nameInSource=null, uuid=mmuuid:29e1f731-d209-4ed8-a96a-ba6c9df38720})
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
Source(groups=[ViewCRM.customers])
============================================================================
EXECUTING AssignOutputElements
AFTER:
Access(groups=[ViewCRM.customers], props={MODEL_ID=Schema name=ViewCRM, nameInSource=null, uuid=mmuuid:29e1f731-d209-4ed8-a96a-ba6c9df38720, OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
Source(groups=[ViewCRM.customers], props={OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber]})
============================================================================
EXECUTING CalculateCost
AFTER:
Access(groups=[ViewCRM.customers], props={MODEL_ID=Schema name=ViewCRM, nameInSource=null, uuid=mmuuid:29e1f731-d209-4ed8-a96a-ba6c9df38720, OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_CARDINALITY=-1.0})
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_CARDINALITY=-1.0})
Source(groups=[ViewCRM.customers], props={OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_COL_STATS={ViewCRM.customers.CIFNo=[-1.0, -1.0], ViewCRM.customers.CustomerType=[-1.0, -1.0], ViewCRM.customers.IDType=[-1.0, -1.0], ViewCRM.customers.IDNumber=[-1.0, -1.0]}, EST_CARDINALITY=-1.0})
============================================================================
EXECUTING PlanSorts
AFTER:
Access(groups=[ViewCRM.customers], props={MODEL_ID=Schema name=ViewCRM, nameInSource=null, uuid=mmuuid:29e1f731-d209-4ed8-a96a-ba6c9df38720, OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_CARDINALITY=-1.0})
Project(groups=[ViewCRM.customers], props={PROJECT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_CARDINALITY=-1.0})
Source(groups=[ViewCRM.customers], props={OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_COL_STATS={ViewCRM.customers.CIFNo=[-1.0, -1.0], ViewCRM.customers.CustomerType=[-1.0, -1.0], ViewCRM.customers.IDType=[-1.0, -1.0], ViewCRM.customers.IDNumber=[-1.0, -1.0]}, EST_CARDINALITY=-1.0})
============================================================================
EXECUTING CollapseSource
AFTER:
Access(groups=[ViewCRM.customers], props={MODEL_ID=Schema name=ViewCRM, nameInSource=null, uuid=mmuuid:29e1f731-d209-4ed8-a96a-ba6c9df38720, OUTPUT_COLS=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber], EST_CARDINALITY=-1.0, ATOMIC_REQUEST=SELECT ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber FROM ViewCRM.customers})
============================================================================
CONVERTING PLAN TREE TO PROCESS TREE
PROCESS PLAN =
AccessNode(0) output=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber] SELECT g_0.CIFNo, g_0.CustomerType, g_0.IDType, g_0.IDNumber FROM ViewCRM.customers AS g_0
============================================================================
----------------------------------------------------------------------------
OPTIMIZATION COMPLETE:
PROCESSOR PLAN:
AccessNode(0) output=[ViewCRM.customers.CIFNo, ViewCRM.customers.CustomerType, ViewCRM.customers.IDType, ViewCRM.customers.IDNumber] SELECT g_0.CIFNo, g_0.CustomerType, g_0.IDType, g_0.IDNumber FROM ViewCRM.customers AS g_0
============================================================================
2012-08-31 17:30:31,889 WARN [org.jboss.resource.connectionmanager.JBossManagedConnectionPool] (Worker21_QueryProcessorQueue137) Throwable while attempting to get a new connection: null
org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml}))
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:225)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:195)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.createConnectionEventListener(InternalManagedConnectionPool.java:639)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.getConnection(InternalManagedConnectionPool.java:273)
at org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.getConnection(JBossManagedConnectionPool.java:746)
at org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:404)
at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:424)
at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:496)
at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:941)
at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:89)
at org.teiid.translator.jdbc.JDBCExecutionFactory.getConnection(JDBCExecutionFactory.java:228)
at org.teiid.translator.jdbc.JDBCExecutionFactory.getConnection(JDBCExecutionFactory.java:56)
at org.teiid.translator.ExecutionFactory.getConnection(ExecutionFactory.java:184)
at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:207)
at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:354)
at org.teiid.dqp.internal.process.DataTierTupleSource.nextTuple(DataTierTupleSource.java:232)
at org.teiid.query.processor.relational.AccessNode.nextBatchDirect(AccessNode.java:271)
at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:280)
at org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:176)
at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:139)
at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:105)
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:147)
at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:375)
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:288)
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:49)
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:216)
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:240)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:122)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:292)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml})
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getDriver(LocalManagedConnectionFactory.java:489)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:206)
... 31 more
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:477)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getDriver(LocalManagedConnectionFactory.java:474)
... 32 more
2012-08-31 17:30:31,911 WARN [org.teiid.CONNECTOR] (Worker21_QueryProcessorQueue137) Connector worker process failed for atomic-request=SIx3npSCPlQy.0.0.25
org.teiid.translator.TranslatorException: Unable to get managed connection for ViewCRM; - nested throwable: (javax.resource.ResourceException: Unable to get managed connection for ViewCRM)
at org.teiid.translator.jdbc.JDBCExecutionFactory.getConnection(JDBCExecutionFactory.java:230)
at org.teiid.translator.jdbc.JDBCExecutionFactory.getConnection(JDBCExecutionFactory.java:56)
at org.teiid.translator.ExecutionFactory.getConnection(ExecutionFactory.java:184)
at org.teiid.dqp.internal.datamgr.ConnectorWorkItem.execute(ConnectorWorkItem.java:207)
at org.teiid.dqp.internal.process.DataTierTupleSource.getResults(DataTierTupleSource.java:354)
at org.teiid.dqp.internal.process.DataTierTupleSource.nextTuple(DataTierTupleSource.java:232)
at org.teiid.query.processor.relational.AccessNode.nextBatchDirect(AccessNode.java:271)
at org.teiid.query.processor.relational.RelationalNode.nextBatch(RelationalNode.java:280)
at org.teiid.query.processor.relational.RelationalPlan.nextBatch(RelationalPlan.java:176)
at org.teiid.query.processor.QueryProcessor.nextBatchDirect(QueryProcessor.java:139)
at org.teiid.query.processor.QueryProcessor.nextBatch(QueryProcessor.java:105)
at org.teiid.query.processor.BatchCollector.collectTuples(BatchCollector.java:147)
at org.teiid.dqp.internal.process.RequestWorkItem.processMore(RequestWorkItem.java:375)
at org.teiid.dqp.internal.process.RequestWorkItem.process(RequestWorkItem.java:288)
at org.teiid.dqp.internal.process.AbstractWorkItem.run(AbstractWorkItem.java:49)
at org.teiid.dqp.internal.process.RequestWorkItem.run(RequestWorkItem.java:216)
at org.teiid.dqp.internal.process.DQPWorkContext.runInContext(DQPWorkContext.java:240)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$RunnableWrapper.run(ThreadReuseExecutor.java:122)
at org.teiid.dqp.internal.process.ThreadReuseExecutor$3.run(ThreadReuseExecutor.java:292)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: org.jboss.util.NestedSQLException: Unable to get managed connection for ViewCRM; - nested throwable: (javax.resource.ResourceException: Unable to get managed connection for ViewCRM)
at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:95)
at org.teiid.translator.jdbc.JDBCExecutionFactory.getConnection(JDBCExecutionFactory.java:228)
... 21 more
Caused by: javax.resource.ResourceException: Unable to get managed connection for ViewCRM
at org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:441)
at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:424)
at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:496)
at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:941)
at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:89)
... 22 more
Caused by: org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml}))
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:225)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.createManagedConnection(LocalManagedConnectionFactory.java:195)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.createConnectionEventListener(InternalManagedConnectionPool.java:639)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.getConnection(InternalManagedConnectionPool.java:273)
at org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.getConnection(JBossManagedConnectionPool.java:746)
at org.jboss.resource.connectionmanager.BaseConnectionManager2.getManagedConnection(BaseConnectionManager2.java:404)
... 26 more
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml})
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getDriver(LocalManagedConnectionFactory.java:489)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getLocalManagedConnection(LocalManagedConnectionFactory.java:206)
... 31 more
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@553bf378{vfsfile:/D:/srv/SOA-P/jboss-as/server/default/deploy/teiid/teiid-jboss-beans.xml}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:477)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Unknown Source)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory.getDriver(LocalManagedConnectionFactory.java:474)
... 32 more
2012-08-31 17:30:31,930 WARN [org.teiid.PROCESSOR] (Worker21_QueryProcessorQueue137) Processing exception 'ViewCRM: Unable to get managed connection for ViewCRM; - nested throwable: (javax.resource.ResourceException: Unable to get managed connection for ViewCRM)' for request SIx3npSCPlQy.0. Exception type org.teiid.core.TeiidProcessingException thrown from org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:477). Enable more detailed logging to see the entire stacktrace.
2012-08-31 17:35:31,826 WARN [com.arjuna.ats.arjuna.logging.arjLoggerI18N] (Thread-16) [com.arjuna.ats.arjuna.coordinator.TransactionReaper_18] - TransactionReaper::check timeout for TX -3f57fd9a:f1e9:50402e3e:3382 in state RUN
2012-08-31 17:35:31,858 WARN [com.arjuna.ats.arjuna.logging.arjLoggerI18N] (Thread-17) [com.arjuna.ats.arjuna.coordinator.TransactionReaper_7] - TransactionReaper::doCancellations worker Thread[Thread-17,5,jboss] successfully canceled TX -3f57fd9a:f1e9:50402e3e:3382