THANK YOU! This resolved my problem. I moved persistence.xml into
WEB-INF/classes/META-INF, and suddenly it all worked. It was a beautiful
moment.
Thanks to all of you who responded. I'll provide some notes from my
experiences below in case anyone else reads this later.
jta-data-source
Hmm, jndi names work great so something might be wrong elsewhere. Would be
great to identify it if thats true.
Le 6 juin 2013 14:36, Andrew Clarke s...@clarke.ca a écrit :
THANK YOU! This resolved my problem. I moved persistence.xml into
WEB-INF/classes/META-INF, and suddenly it all worked.
I've set up my database in TomEE such that it works fine with SQL Query. When
I attempted to do a simple entityManager.find() as a JPA test, I got the
following error:
java.lang.RuntimeException: org.apache.cxf.interceptor.Fault: The bean
encountered a non-application exception; nested
Andrew,
Did you try using the setting exclude-unlisted-classes, with the value of
false?
John
On Wed, Jun 5, 2013 at 8:27 PM, Andrew Clarke s...@clarke.ca wrote:
I've set up my database in TomEE such that it works fine with SQL Query.
When I attempted to do a simple entityManager.find() as
Yes I did, thanks. I did mention that in the email, but I know there was a lot
in there. This was the syntax of my persistence.xml when I tried that:
persistence xmlns=http://java.sun.com/xml/ns/persistence;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
Hmm yeah I missed that part.
So wait, is your persistence.xml in your war file somewhere? Where is it?
How do you get a reference to your entity manager?
On Wed, Jun 5, 2013 at 8:39 PM, Andrew Clarke s...@clarke.ca wrote:
Yes I did, thanks. I did mention that in the email, but I know there
Thanks again John. I'll include an example TestManagerBean.java below. My
persistence.xml is in my WAR file under /META-INF.
package com.example;
import com.example.account.Application;
import com.example.system.SystemPropertiesBean;
import org.apache.commons.logging.Log;
import
responses inline below...
On Wed, Jun 5, 2013 at 8:27 PM, Andrew Clarke s...@clarke.ca wrote:
persistence.xml:
persistence xmlns=http://java.sun.com/xml/ns/persistence; xmlns:xsi=
http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=
http://java.sun.com/xml/ns/persistence
So, the root META-INF?
What happens when it goes in WEB-INF/classes/META-INF ?
On Wed, Jun 5, 2013 at 9:29 PM, Andrew Clarke s...@clarke.ca wrote:
Thanks again John. I'll include an example TestManagerBean.java below.
My persistence.xml is in my WAR file under /META-INF.
package
responses inline below...
On Wed, Jun 5, 2013 at 8:27 PM, Andrew Clarke s...@clarke.ca wrote:
persistence.xml:
persistence xmlns=http://java.sun.com/xml/ns/persistence; xmlns:xsi=
http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=
http://java.sun.com/xml/ns/persistence
Good catch, but AFAIK, Hibernate ignores the version of persistence.xml
(typically). Unless TomEE cares...
On Wed, Jun 5, 2013 at 9:39 PM, Howard W. Smith, Jr. smithh032...@gmail.com
wrote:
responses inline below...
On Wed, Jun 5, 2013 at 8:27 PM, Andrew Clarke s...@clarke.ca wrote:
Yes there is no difference afair in that area in jpa 2.
Just to be sure, are you delivering hibernate within you webapp?
By default, we use openjpa so you need hibernate in your webapp.
As per the spec and again afair entities get detected and added
automatically if and only if they are fine the
12 matches
Mail list logo