This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes how to forcefully log out in admin module? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Reply locked New topic
Author

how to forcefully log out in admin module?

shyam ji gautam
Ranch Hand

Joined: Sep 17, 2011
Posts: 48
Dear all
intime:


i am making an application in which admin can forcefully log out the online user .
because only one user can login only one time by using same id and password

so my database design is like this table name:user maintenance
colunm name is
userid: flag : logintime :logouttime

algorithms for this is like
1) by default flag is 'y' so when user going to login check it is set to 'y' or when it is log out it will set to 'N'
2)after session time out to set flag i am using listener which set the flag automatically 'Y' after session time out
3) so for me online user = select * from usermaintenance where flag = 'N' which will be seen to admin

but my doubt is that some user directly close the browser and go , so he actually not online but he will be count as online because flag for them is still set to 'N'

SO My concern is that how any java/j2ee approach we can differentiate between real online and such user which can close the browser

thanks

Matthew Brown
Bartender

Joined: Apr 06, 2010
Posts: 4344
    
    8

This is a duplicate of http://www.coderanch.com/t/554254. Please UseOneThreadPerQuestion. Thanks.
 
Consider Paul's rocket mass heater.
 
subject: how to forcefully log out in admin module?
 
Similar Threads
Prevent multiple concurrent logins from same user in clustered env
can we invalidate the session of second user ?
how to forcefully log out in admin module?
HOW TO RESTRICT USER FROM LOGGING FROM TWO MACHINE
How to get session object by giving Session Id to kill another session in Websphere