Connected users

Is it possible to have the connected users list in my application and the possibility to disconnect one or all of them.

Thank you.

Are you using one server or a clustered deployment? If everyone is sharing a JVM, why not maintain the list in a static set?

I’ve seen a clustered solution that stored the session validity “keys” in a database. It requires some legwork on upkeeping, and on every request there is a database overhead to check if the session is valid, but the solution is very straightforward to implement.

You could also use memcached or something similar instead of a database, but if your environment is not clustered a simple static data structure is indeed the easiest way to go.

Hi,
Thank you for responses.
My team and I will investigate about this and will give you the result.
Sincerely.