users@glassfish.java.net

Re: v3: problem deploying exploded ear with exploded shared entity lib

From: <glassfish_at_javadesktop.org>
Date: Fri, 26 Mar 2010 03:17:34 PDT

Dear all,

I'm experiencing the same problem as yours, and I'm actually making a kind of hello-world app. So let me send you a tiny ear file wich reproduces the problem.

Thank you for help !

Here is a part of the stack trace :

...
Caused by: java.lang.IllegalStateException: Unable to retrieve EntityManagerFactory for unitName null
        at com.sun.enterprise.container.common.impl.EntityManagerWrapper.init(EntityManagerWrapper.java:121)
        at com.sun.enterprise.container.common.impl.EntityManagerWrapper._getDelegate(EntityManagerWrapper.java:162)
        at com.sun.enterprise.container.common.impl.EntityManagerWrapper.createNamedQuery(EntityManagerWrapper.java:521)
        at fr.compmany.tests.helloapp.session.HelloWorld.getAllMedecinsNames(HelloWorld.java:50)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
...


The call refers to HelloWorld.getAllMedecinsNames method, wich tries to query the database.
To run the program : Deploy the web application, connect to http://localhost:8080/HelloApplicationWeb and call the Servlet from the link.

Thanks a lot
[Message sent by forum member 'laps']

http://forums.java.net/jive/thread.jspa?messageID=393870