-
1. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
unsavory Apr 18, 2007 9:55 PM (in response to unsavory)Sorry, please ignore the stack trace posted above. It should read:
javax.naming.NameNotFoundException: TestBean not bound org.jnp.server.NamingServer.getBinding(NamingServer.java:491)
-
2. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
fhh Apr 19, 2007 12:00 PM (in response to unsavory)Your @local annotation is missing.
Regards
Felix -
3. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
unsavory Apr 19, 2007 12:44 PM (in response to unsavory)From reading the documentation I shouldn't need @local for a stateless session bean right? Or am I missing something?
All the examples I look at do not have the @local annotation.
Where would I put that annotation? On the interface? Thanks. -
4. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
unsavory Apr 19, 2007 1:44 PM (in response to unsavory)Ok, I found this in the JBoss docs.
"EJB 3.0 beans must be packaged in a JAR file with the suffix .jar. "
http://docs.jboss.org/ejb3/app-server/tutorial/stateless/stateless.html
Does anyone know if it is possible to have the JBoss deployer scan for class files outside of a .jar? -
5. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
fhh Apr 19, 2007 2:51 PM (in response to unsavory)
From reading the documentation I shouldn't need @local for a stateless session bean right?
Nope. On the the page you linked in your first ppost it clearly says:
Take a look at CalculatorRemote.java. To define this as the remote interface of Calculator bean you either annotate the bean class and specify what the remote interfaces are, or you annotate each remote interface the bean class implements with @javax.ejb.Remote. only need to annotate the bean class with @javax.ejb.Remote. Similar for CalculatorLocal.java as you need to annotate the bean class with @javax.ejb.Local for it to be the local interface of the CalculatorBean.
Regards
Felix -
6. Re: JNDI in Jboss EJB3 Embeddable Container: Naming Problem
unsavory Apr 19, 2007 4:36 PM (in response to unsavory)Thanks Felix.
Even after adding the @Local annotation, it is still not working. I even tried adding my bean to the persistence.xml file as follows:
test.TestBean
No go. Any ideas here?