Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

What is Session LifeCycle Event handling?

 
Rakesh Mehra
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Session life cycle consists of:
1. Creation of a newsession. 2. Invalidation of Session

I'm unable to understand the below.How do we implement them.An example would be helpful.

In addition,a container may passivate and acivate sessions.The Servlet API includes event-handling mechanisms whereby objects(either session or others) can be notified abot passivation and activation The following are the event listeners:

HttpSessionListener and HttpSessionActivationlistener.

For both eent listeners the container encapsulates the asociated event as HttpSessionEvent object
.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 35757
412
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are APIs for both:
1) request.getSession()
2) session.invalidate()
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!