In my web application i need to restrict the maximum number of user accessing my web application.The no of users are configured in a separate properties file.I have created a HttpSessionListener interface to track different users but the problem am facing is that one user can request using multiple instances of browser and the number of users gets increased by 1 even though the same user with different browser instance.i need to count the users based on different IP address or some other unique parameter.
A possibility could be to use session cookies - if the new connected user doesn't have a session cookie, give them one and increment your counter, otherwise don't increment the counter.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With