permaculture playing cards*
The moose likes JSP and the fly likes Active Sessions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Active Sessions" Watch "Active Sessions" New topic
Author

Active Sessions

Afroz Ahmed
Ranch Hand

Joined: Jan 18, 2004
Posts: 64
Hello,

I am a learner..help me...

I am doing my application on tomcat servlet container.

1)I wanted to know how many sessions are running for my web application and the information of users,who were assigned to those sessions.

2)Can i stop a session from the list of sessions running,if i had permissions to do that.How to do that?

3)Can i restrict only one user can login at a time with a userid/pwd.
Such that no other person can login into my application with the same userid/pwd upto the first user is loggedout.How to do that?

Thanks & Regards
Afroz Ahmed


The value of an idea lies in the usage of it.
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
Hi,
You can add the user to the session as an attribute, after login. For restricting duplicate login, you can use SessionBindingListener and methods _Bound() and _unBound().
Regards,
Gajanan C
Afroz Ahmed
Ranch Hand

Joined: Jan 18, 2004
Posts: 64
Hello Gajanan,

It is working fine for duplicate user.Thanks a lot.

Can you give me clarification regarding other probs too.

Thanks..
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Active Sessions
 
Similar Threads
What should we do about Login?
response.sendRedirect not working from bean
How to share value between mutiple war files?
please help me to solve following spring issues
How to secure my page