[jbdevstudio-users] Setting up datasource in JBoss
Swetal Parikh
jbdevstudio-users at lists.jboss.org
Tue Apr 22 11:07:50 EDT 2014
Hello,
I am new to JBoss. I downloaded JBoss Developer Studio
JBoss Enterprise Application Platform - Version 6.2.0.GA
I am trying to setup MySQL as datasource and it is not able to recognize my XML.
I copied mysql-connector-java-5.1.30-bin.jar in jboss-eap\standalone\lib directory. Then I placed mysql-ds.xml in jboss-eap\standalone\deployments directory. Following is the content of mysql-ds.xml:
<?xml version="1.0" encoding="UTF-8"?>
<datasources>
<datasource>
<jndi-name>java:/DefaultDS</jndi-name>
<connection-url>jdbc:mysql://localhost:3306/test</connection-url>
<driver-class>com.mysql.jdbc.Driver</driver-class>
<user-name>root</user-name>
<password>test1102</password>
<valid-connection-checker-class-name>org.jboss.resource.adapter.jdbc.vendor.MySQLValidConnectionChecker</valid-connection-checker-class-name>
<metadata>
<type-mapping>mySQL</type-mapping>
</metadata>
</datasource>
</datasources>
When I restart JBoss server from my JBDevStudio. I see following message in the console:
09:44:25,580 INFO [org.jboss.as.controller] (Controller Boot Thread) JBAS014774: Service status report
JBAS014777: Services which failed to start: service jboss.deployment.unit."mysql-ds.xml".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.unit."mysql-ds.xml".PARSE: JBAS018733: Failed to process phase PARSE of deployment "mysql-ds.xml"
I will appreciate if someone can shed some light on what am I doing wrong here.
Thanks,
Swetal
Posted by forums
Original post: https://community.jboss.org/message/869775#869775
More information about the jbdevstudio-users
mailing list