> -----Original Message-----
> From: Sachin Tyagi [mailto:[EMAIL PROTECTED]]
> Sent: January 18, 2002 5:22 AM
> To: [EMAIL PROTECTED]
> Subject: No. of User Restrictor
>
>
> Hi All
>
> I am looking for a functionality with my web application I need some
> suggestions. Application running on Apache 1.3 and Tomcat3.2(4.0 optional)
> What I need is
> we want to restrict the no. of user connected to our application
> for example
> If we need only 50 user can  be connected not more than that ...so how we
> can implement that or what approch should be taken.
> Basically Tomcat or with apache  server does not respond to more
> than no. of
> defined user...so how that can be accomplished in any way..?using
> session or
> else.??
> So if any one have any idea of that plz fwd.
>
> Regds
> Sachin

This should be fairly easy to implement in your application.  You should
simply establish a logged-in user counter of some sort, perhaps
increment/decrement a field in your database, and make your login
JSP/servlet check that counter as part of the login process.  You can then
deliver a custom message to the user when he/she attempts to login when the
number of users has reached your pre-set limit.  You can even set the limit
as in the web.xml, e.g.

<init-param>
  <param-name>userLimit</param-name>
  <param-value>50</param-value>
</init-param>

so that you can easily change it at a later stage.




Emir.


--
To unsubscribe:   <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>

Reply via email to