Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB 3.0 Remote interface invocation issue!!

 
Mohammed Shafique
Greenhorn
Posts: 1
Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i am trying to develope simple EJB Application after a long time & facing a strange problem,
i have developed a simple Enterprise Application , having a Web module & an EJB module,
and using JSP page as a client, in jsp page i have written code like this given below


when i am running application i can see this System.out.println(hel.hello("hi")+ " Returned this") line output on console , but when
i am trying to show this output on my web page using this code

in the same JSP page i am getting null, in fact i tried to debug it, & found that control is not reaching to this
result = result + hel.hello(name); in the above mentioned, later fragment of code.
why it is happening, i have checked all dependencies of EAR file, & WER file, even i m facing this problem, what is my mistake,

Can any one please help me out,
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34835
369
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What exception is happening here:

You'll need to add code to find out. Right now, the code hides the exception so you can't know what is wrong.

Also, note it is bad practice to put Java code in new JSPs.
 
massimiliano cattaneo
Greenhorn
Posts: 24
Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
Who sets the parameter named "name" ?
if this "name = request.getParameter("name");" return null, all the code is skipped so the behaviour is right.

What is printed by the two lines of code ?

Please use the "code" to post the code in the forum

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic