Unable to start the ds because it generated more than one cf
vpyang Dec 14, 2016 2:11 PMHello,
I'm getting this error when trying to add a datasource to wildfly10. Seems to be working for wildfly9. When I run the file with the following from jboss-cli:
connect
batch
data-source add \
--name=my-ds \
--driver-name=ojdbc6-11.2.0 \
--driver-class=oracle.jdbc.OracleDriver \
--connection-url=jdbc:oracle:thin:@mydb \
--jndi-name=java:/jdbc/my-ds \
--user-name=myuser \
--password=mypwd \
data-source enable --name=my-ds
run-batch
reload
I get the following error:
ERROR [org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService$AS7DataSourceDeployer] (MSC service thread 1-7) Error during the deployment of java:/jdbc/my-ds: javax.resource.ResourceException: IJ031103: At least one connection property must be defined for datasource-class: oracle.jdbc.driver.OracleDriver
at org.jboss.jca.adapters.jdbc.local.LocalManagedConnectionFactory.createConnectionFactory(LocalManagedConnectionFactory.java:108)
at org.jboss.jca.deployers.common.AbstractDsDeployer.deployDataSource(AbstractDsDeployer.java:772)
at org.jboss.jca.deployers.common.AbstractDsDeployer.createObjectsAndInjectValue(AbstractDsDeployer.java:312)
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService$AS7DataSourceDeployer.deploy(AbstractDataSourceService.java:371)
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:149)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC000001: Failed to start service org.wildfly.data-source.my-ds: org.jboss.msc.service.StartException in service org.wildfly.data-source.my-ds: WFLYJCA0033: Error during the deployment of my-ds
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:163)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
Caused by: org.jboss.msc.service.StartException in anonymous service: WFLYJCA0032: Unable to start the ds because it generated more than one cf
at org.jboss.as.connector.subsystems.datasources.AbstractDataSourceService.start(AbstractDataSourceService.java:151)
... 5 more
My driver is config as follow:
<driver name="ojdbc6-11.2.0" module="com.oracle">
<datasource-class>oracle.jdbc.driver.OracleDriver</datasource-class>
</driver>
and the module is config as follow:
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.1" name="com.oracle">
<resources>
<resource-root path="ojdbc6-11.2.0.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
I'm running this from standalone. What am I missing/doing wrong here?