How many ways to remove the session object in the container
Answer Posted / amitasite
Programmatically:
1. session.invalidate()
2. session.setMaxInteractiveIntervals(0);
Container will remove session if user is idle more than the
time specified in <session-timeout>time in
minutes</session-timeout> in web.xml
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
How do you invoke a Servlet? What is the difference between doPost method and doGet method?
What is the use of send redirect () method?
What is servlet? Explain
Can we use the constructor, instead of init(), to initialize servlet?
What are the differences between servlet context vs servlet config?
what is multiple server?
When a servlet accepts a call from a client, it receives two objects. What are they?
How many servlet objects are created?
Explain web application directory arrangement?
What is cookie? Why is cookie used?
What is pure servlet?
Why is http protocol called as a stateless protocol?
Why do you use session tracking in httpservlet?
How to notify an object in session when session is invalidated or timed-out?
What are the functions of Servlet container?