Hi,

I am using Cocoon 2, with a DatabaseAuthenticatorAction to validate user
logins.  What I need to be able to do though is limit each user to only
being logged in once, and also limit the total number of logged in users
at any one time, to some limit (say 20).

Does anyone have any bright ideas of how I might go about enforcing
this?

I had thought about having a "logged in" boolean in the users table in
the database, and add an extra rule such that a user can't log in if
this is already set... but that raises the question of what to do for
someone not logging out properly/their web browser crashing, and then
gets into a whole rat's nest of timeouts and forced logouts...

One other idea I had was for the web pages to have a small applet which
communicates back with the web server, acting as some kind of
heartbeat.  Something on the server end then needs to update the users
table with the last heartbeat time.  This though is really a last resort
option, as it means introducing a frames just so the applet remains
across the whole site, and as the number of logged in users increases,
the extra network traffic just gets silly.

Any suggestions/ideas/examples are appreciated,
cheers,
David.



---------------------------------------------------------------------
Please check that your question has not already been answered in the
FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>

To unsubscribe, e-mail: <[EMAIL PROTECTED]>
For additional commands, e-mail: <[EMAIL PROTECTED]>

Reply via email to