Hi
I'm running into a very pecuilar problem. I have no problem running my application with JBPM with persistence in my Eclipse IDE enviroment as a standalone app. However, when I export it into a runnable jar, I get this error:
javax.persistence.PersistenceException: Unable to configure EntityManagerFactory at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:378) at org.hibernate.ejb.HibernatePersistence.createEntityManagerFactory(HibernatePersistence.java:56) at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:48) at javax.persistence.Persistence.createEntityManagerFactory(Persistence.java:32)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1 at java.lang.String.substring(String.java:1937) at org.hibernate.ejb.packaging.JarVisitorFactory.getJarURLFromURLEntry(JarVisitorFactory.java:55) at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:344) ... 64 more
This is after I've removed the following jar since I get other set of errors if I include these 2 jars in my standalone jar executable
ejb3-persistence-1.0.2-GA.jar
persistence-api-1.0.jar
I'm assuming that persistence.xml and orm.xml has to be stored in a different location instead of META-INF/ for a standalone j2se app ? I've tried it in other locations but no luck.
Any suggestions ?
Dave