This content has been marked as final.
Show 3 replies
-
1. Re: NullPointerException in HelloWorld
peterj Jul 11, 2006 11:06 AM (in response to qbacomarch)Since your client is a standalone application, the @EJB annotation is ignored. Hence the NPE.
-
2. Re: NullPointerException in HelloWorld
qbacomarch Jul 12, 2006 3:08 AM (in response to qbacomarch)And what to do with this NPE??
-
3. Re: NullPointerException in HelloWorld
wolfc Jul 12, 2006 5:27 AM (in response to qbacomarch)Try the following code:
InitialContext ctx = new InitialContext(); HelloRemote bin = (HelloRemote) ctx.lookup("HelloBean/remote");
It needs some exception handling.
Depending on the method of deployment the JNDI name may vary. Look in the JMX console -> JNDIView for the true name.