This content has been marked as final.
Show 4 replies
-
1. Re: referencing session bean from servlet.
wauwau0977 May 27, 2006 11:00 AM (in response to doubledenim)hi
jboss fulfills the latest sun spec, which changed the lookup.
try thisctx.lookup("yourEJBProject/BeanName/remote|local");
regards,
patrick heusser
--
patrick heusser
http://www.x8ing.com/fractal/ -
2. Re: referencing session bean from servlet.
doubledenim May 27, 2006 9:22 PM (in response to doubledenim)thanks for that.
When you say yourEjbProject, do you mean the package path? -
3. Re: referencing session bean from servlet.
doubledenim May 27, 2006 11:02 PM (in response to doubledenim)I've tried the following.
ctx.lookup("ejb/Session/remote");
and get "ejb not bound"ctx.lookup("Session/remote");
and get "Session not bound"
What is the correct syntax for this?
Thanks -
4. Re: referencing session bean from servlet.
amit.bhayani May 28, 2006 2:51 AM (in response to doubledenim)Its not necessary that you follow the default. You can provide the JNDI name for your bean using @RemoteBinding annotation. For ex
@Stateless
@RemoteBinding(jndiBinding="MyStatelessRemote")
public class MyStatelessBean implements MyStatelessRemote
{
----
----
---
}
Client Code
Object ref = jndiContext.lookup("MyStatelessRemote");