How to pass session values from one servlet container to another servlet container? or how can we get session values of one container in another container?
Answer Posted / mohit rana
It's simple just use session (session object).
HttpSession session = request.getSession();
session.setAttribute(String obj);
and get the above value on other container
session.getAttribute(String obj);
Is This Answer Correct ? | 16 Yes | 5 No |
Post New Answer View All Answers
What is the difference between get and post methods?
What are the life-cycle methods for a servlet?
How can the referrer and the target urls be used in servlet?
What is cookie? Why is cookie used?
What are some advantages of storing session state in cookies?
What's the difference between servlets and applets?
How would you create deadlock on your servlet?
What are some disadvantages of storing session state in cookies?
What is difference between ServletResponse sendRedirect() and RequestDispatcher forward() method?
Explain how to improve Servlet Performance?
What is the directory structure of a war file?
Which exception is thrown if the servlet is not initialized properly?
Write a simple servlet program to print the contents of html.
What are the supporting protocol by HttpServlet ?
Explain the difference between servletconfig and servletcontext in servlet?