This content has been marked as final.
Show 2 replies
-
1. Re: config for using persistence.xml
marcreis Jun 14, 2006 8:46 AM (in response to marcreis)Just saw that I have a typo in the post, both ds have the same name java:/jdbc/OLGAENTW and are not different.
By misstake I copied the first code snipit with java:/jdbc/MYDB. -
2. Re: config for using persistence.xml
marcreis Jun 16, 2006 6:38 AM (in response to marcreis)I am still having the problem... I can configure it as an MBean (hibernate-service.xml) and it works fine, use a utility class for a static factory and the hibernate.cfg.xml and it works.
But with the persistence.xml, it seems I am missing something. I read over the documentation again and again (JBossAS, EJB3Persistence, TrailBlaizer etc.) since I thought my question is to obvious...
If it is, please still feel free to mention it to me ;).
I hope my persistence.xml and the mydata-ds.xml give some hints (these are the minimalistic versions)....
Thanks!<persistence> <persistence-unit name="entwDS"> <provider>org.hibernate.ejb.HibernatePersistence</provider> <jta-data-source>jdbc/OLGAENTW</jta-data-source> <properties> <property name="hibernate.dialect" value="org.hibernate.dialect.Oracle9Dialect"/> <property name="hibernate.hbm2ddl.auto" value="create-drop"/> </properties> </persistence-unit> </persistence>
and the data source file...<?xml version="1.0" encoding="UTF-8"?> <datasources> <local-tx-datasource> <jndi-name>/jdbc/OLGAENTW</jndi-name> <connection-url>jdbc:oracle:thin:@somewhere.de:1234:olgaentw</connection-url> <driver-class>oracle.jdbc.driver.OracleDriver</driver-class> <exception-sorter-class-name>org.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter</exception-sorter-class-name> <metadata> <type-mapping>Oracle</type-mapping> </metadata> </local-tx-datasource> <datasources>
leads to12:34:54,515 INFO [EJB3Deployer] Deployed: file:/C:/work/_programme/jboss-4.0.4 .GA-ejb3/server/default/deploy/EJBTest2EJB.jar 12:34:54,609 ERROR [URLDeploymentScanner] Incomplete Deployment listing: --- MBeans waiting for other MBeans --- ObjectName: persistence.units:jar=EJBTest2EJB.jar,unitName=entwDS State: NOTYETINSTALLED I Depend On: jboss.jca:name=jdbc/OLGAENTW,service=ManagedConnectionFactory --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM --- ObjectName: jboss.jca:name=jdbc/OLGAENTW,service=ManagedConnectionFactory State: NOTYETINSTALLED Depends On Me: persistence.units:jar=EJBTest2EJB.jar,unitName=entwDS