I am trying to execute org.apache.openjpa.persistence.datacache.CacheTest
with a custom cache provider. 

In spite of having ALL entity classes on the classpath when executing the
test, openJPA complains that 
the entity was not found in the list of persistent types.

<openjpa-2.0.0-SNAPSHOT-r422266:824213 fatal user error>
org.apache.openjpa.persistence.ArgumentException: No metadata was found for
type "class
org.apache.openjpa.persistence.datacache.common.apps.CacheObjectA". The
class does not appear in the list of persistent types:
[org.apache.openjpa.persistence.common.apps.Student, ...........].

When I decompiled CacheObjectA in
C:\open-jpa\openjpa-trunk\openjpa-persistence-jdbc\target\test-classes\org\apache\openjpa\persistence\datacache\common\apps,
I saw that CacheObjectA implements  PersistenceCapable which means that the
enhancer did its job.

The surefire plugin test classpath does contain the
C:\open-jpa\openjpa-trunk\openjpa-persistence-jdbc\target\test-classes dir
on its classpath

What does one need to do to get OpenJPA to recognize a persistence capable
class ?
Is it necessary for all persistable entities to be defined in the orm xml
files in addition to having the @Entity annotation ?

--Thanks,
Rohit Kelapure
-- 
View this message in context: 
http://n2.nabble.com/Running-CacheTest-class-does-not-appear-in-the-list-of-persistent-types-tp3810164p3810164.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.

Reply via email to