[jboss-user] [EJB 3.0] - Writting ejb3 session bean + howto session bean lookup?
fbadt
do-not-reply at jboss.com
Tue Nov 7 16:08:49 EST 2006
There is a web service (stateless session bean with annotations) that needs to call another session bean with annotations.
1. do ejb3 session beans need to have local/remote interfaces like ejb1.4?
2. how can sessionbean1 lookup sessionbean2? The below code results in an exception that sessionbean2 is not registered. The logs and JMX console say that sessionbean2 was published with name=sessionbean2 This is jboss 4.0.4
| try {
| context = new InitialContext();
| retVal = (sessionbean2LocalInterface)
| context.lookup("sessionbean2");
| } catch (NamingException e) {
| e.printStackTrace();
| throw new RuntimeException(e);
| }
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3983920#3983920
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3983920
More information about the jboss-user
mailing list