Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Session Expiration and Beans  RSS feed

 
David Baranas
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How would I trigger a bean to record session information to a database upon the session expiring?
Thanks!
 
Dinesh Kumar
Ranch Hand
Posts: 54
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi David,
I think you should try HttpSessionBindingListener. It can listen to session un-binding events. It's explained with an exmaple in the "Professional JSP" book by Wrox.
You can use it in a bean too. The bean method can simply implement this interface.
Hope it helps.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!