Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Servlet, JSP and a Stateful Session Bean  RSS feed

 
Paul McKenna
Ugly Redneck
Ranch Hand
Posts: 1006
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi folks..
I have a stateful session bean, to which I have obtained the remote interface inside a servlet. The servlet needs to call a JSP and pass this remote reference onto the JSP so that the JSP can utilize the same stateful bean.
Any clues??
 
ravi janap
Ranch Hand
Posts: 389
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear Sriraj,
you can pass the reference of the remote from a servlet to a jsp using session tracking API.
in the servlet say
Session s = req.getSession(true);
s.setAttribute("remote",xyzRemote);
in the jsp
<@ page import="xyzRemote.class" >
xyzRemote r = (xyxRemote)Session.getAttribute;("remote");
you have to copy xyzRemote.class to weblogic/class/com directory.
regards
Ravindra

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!