wood burning stoves 2.0*
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 EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Active Sessions" Watch "Active Sessions" New topic

Active Sessions

Afroz Ahmed
Ranch Hand

Joined: Jan 18, 2004
Posts: 64

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.
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
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().
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.

I agree. Here's the link: http://aspose.com/file-tools
subject: Active Sessions
Similar Threads
What should we do about Login?
How to secure my page
How to share value between mutiple war files?
please help me to solve following spring issues
response.sendRedirect not working from bean