[jboss-user] [Datasource Configuration] - JNDI and Data Source Configuration

Tharindu Malimage do-not-reply at jboss.com
Mon Jul 26 04:24:21 EDT 2010


Tharindu Malimage [http://community.jboss.org/people/tmalimage] replied to the discussion

"JNDI and Data Source Configuration"

To view the discussion, visit: http://community.jboss.org/message/554342#554342

--------------------------------------------------------------
I have placed datasource, called *jdbc-ds.xml*

<?xml version="1.0" encoding="UTF-8"?>
<datasources>
    <local-tx-datasource>
        <jndi-name>jdbc/uni</jndi-name>
        <connection-url>jdbc:mysql://localhost:3306/Malimage</connection-url>
        <driver-class>com.mysql.jdbc.Driver</driver-class>
        <user-name>****</user-name>
        <password>******</password>
           <metadata>
           <type-mapping>mySQL</type-mapping>
        </metadata>
    </local-tx-datasource>
</datasources>

This is my *persistence.xml* file

<?xml version="1.0" encoding="UTF-8"?>
<persistence version="1.0" xmlns=" http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence" xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation=" http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence  http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
  <persistence-unit name="Ent-ejbPU" transaction-type="JTA">
    <provider>org.hibernate.ejb.HibernatePersistence</provider>
    <jta-data-source>java:/jdbc/uni</jta-data-source>
    <exclude-unlisted-classes>false</exclude-unlisted-classes>
    <properties/>
  </persistence-unit>
</persistence>


What is the fault with this?

--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/554342#554342]

Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2077]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100726/347a9310/attachment-0001.html 


More information about the jboss-user mailing list