Dear Fareed
Try the following code.

The Donor Servlet
##################
String name= new String("Rashid Amin");
          HttpSession hs=req.getSession(true);
          try{
          hs.putValue("myParam",name);
          }  catch(IllegalStateException e){System.out.println(e);}

          }

The Recipient Servlet
####################
     String name= "";
               HttpSession hs=req.getSession(true);
               try{
               name= (String)hs.getValue("myParam");
               }  catch(IllegalStateException e){System.out.println(e);}





Syed Fareed Ahmad <[EMAIL PROTECTED]> on 04/05/2000 03:41:56 PM

Please respond to "A mailing list for discussion about Sun Microsystem's Java
      Servlet API Technology." <[EMAIL PROTECTED]>

To:   [EMAIL PROTECTED]
cc:    (bcc: Rashid Amin/CresSoft)

Subject:  Re: any suggestions for global session maintenance



Hi,

How about saving the data using the ServletContext.setAttribute("..","..") and
ServletContext.getAttribute(".."). Every Web app is given separate Context so it
will be global at the level of a Web app

Fareed




Krishna Kamath <[EMAIL PROTECTED]> on 04/05/2000 12:47:36 PM

Please respond to "A mailing list for discussion about Sun Microsystem's Java
      Servlet API Technology." <[EMAIL PROTECTED]>

To:   [EMAIL PROTECTED]
cc:    (bcc: Syed Fareed Ahmad/PK/ABNAMRO/NL)
Subject:  any suggestions for global session maintenance



Hi,
        I have a problem of session maintenance,I would like to know how
tomaintain a global sesion object
which can be accessed by all the requests from many clients(browsers).
For ex.
If a user logins into the application from one browser instance i have to store
his id in a session so that the concurrent
logins from another browser instance or from any other machine should give a
simultaneous  login .....by getting
the userid from the session.
we are using

weblogic 5.0 B2
Servlet 2.2

Thankyou
Kamath Krishna

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html





_________________________________________________________________________

Disclaimer:

"This  message is confidential. It may also be privileged or otherwise protected
by  legal  rules. If you have received it by mistake please let us know by reply
and then delete it from your system."

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to