You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the persistence.xml does not contain a <jar-file> tag the BaseAnnotadedClassLocator will encounter an "vfs" jar URL protocol in the locateClasses method and try to use JBoss7AnnotatedClassLocator. This will fail since JBoss7AnnotatedClassLocator tries to load org.jboss.as.jpa.spi.PersistenceUnitMetadata that not is available in JBoss 6.
It is almost possible to work around this when working with exploded libraries in Eclipse by specifying an relative path
<jar-file>file:../server/default/deploy/{name-of-ear-directory}/lib/{name-of-jpa-jar.jar}<jar-file> in persistence.xml. This will force the usage of the JarAnnotatedClassLocator that according to the logs will locate the annotated classes but at a later stage the JBoss7AnnotatedClassLocator seems to be invoked anyway and you end up with the same missing classes again. Even if this would work the relative path to the JAR file is not an option since it will fail when deployed to a server where exploded libraries isn't used.
The text was updated successfully, but these errors were encountered:
If the persistence.xml does not contain a <jar-file> tag the BaseAnnotadedClassLocator will encounter an "vfs" jar URL protocol in the locateClasses method and try to use JBoss7AnnotatedClassLocator. This will fail since JBoss7AnnotatedClassLocator tries to load org.jboss.as.jpa.spi.PersistenceUnitMetadata that not is available in JBoss 6.
It is almost possible to work around this when working with exploded libraries in Eclipse by specifying an relative path
<jar-file>file:../server/default/deploy/{name-of-ear-directory}/lib/{name-of-jpa-jar.jar}<jar-file> in persistence.xml. This will force the usage of the JarAnnotatedClassLocator that according to the logs will locate the annotated classes but at a later stage the JBoss7AnnotatedClassLocator seems to be invoked anyway and you end up with the same missing classes again. Even if this would work the relative path to the JAR file is not an option since it will fail when deployed to a server where exploded libraries isn't used.
The text was updated successfully, but these errors were encountered: