On 13 August 2013 13:24, Daniel Mikusa <dmik...@gopivotal.com> wrote:

> On Aug 13, 2013, at 6:43 AM, "Smith, Mitchell" <mitchell.sm...@cwc.com>
> wrote:
>
> > Hi,
> >
>
> What version of Tomcat are you using?  6.0.x or 7.0.x?
>
Tomcat7

>
> > I was looking at using the maxActiveConnections in the application
> context,
>
> Please include the relevant configuration from your server.xml or
> context.xml file.
>
Context.xml

> <Context>
>
>     <!-- Default set of monitored resources -->
>
>     <WatchedResource>WEB-INF/web.xml</WatchedResource>
>
>     <!-- Uncomment this to disable session persistence across Tomcat
> restarts -->
>
>     <Manager pathname=""
>      *maxActiveConnections="150"
> */>
>     <!-- Uncomment this to enable Comet connection tacking (provides events
>          on session expiration as well as webapp lifecycle) -->
>     <!--
>     <Valve
> className="org.apache.catalina.valves.CometConnectionManagerValve" />
>     -->
> </Context>
>
>
>  > what I find is. When I reach the limit, as expected the server will not
> > create a new session, however does return a http 200 status code.
> >
> > I am wondering would it be possible for me to change this behavior to
> > return say a 300 range code to redirect to (in a production environment)
> > load balancer.
> >
> > I can see some potential issues with this, like the possibility of an
> > infinite loop, but for now I am just exploring possible ways to prevent
> my
> > tomcat servers becoming overloaded.
>
> How do you have your load balancer setup now?  What software / hardware
> are you using?  What algorithm is it using to distribute the load?
>
Its an apache httpd server, distributing load using byRequest, with a
redundant fail-over node configured howevr this only works if the tomcat
server fails to accept the initial connection

>
> >
> > Does anyone have any thoughts or ideas for this type of solution?
>
> Perhaps you need to adjust the load balancer so it's spreading out the
> connections more evenly?  Perhaps you need to add another node to handle
> the load?
>
> Its a recent issue, typical user response to a slow application (for
whatever reason) is to open another session, however the jvmRoute is stored
in the browser which forces the 2nd,3rd,4th.... session to the same host.

We are looking at a application solution to provide a new session without
the jvmRoute in separate tabs, but the ability to reject and redirect a
user (even to a error page) when the server limit we set is reached would
prevent a larger scale outage.


Dan
>
>
> >
> > Regards
> > --
> > *Mitchell Smith
> > *
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

The information contained in this email (and any attachments) is confidential 
and may be privileged. If you are not the intended recipient
and have received this email in error, please notify the sender immediately by 
reply email and delete the message and any attachments.
If you are not the named addressee, you must not copy, disclose, forward or 
otherwise use the information contained in this email.
Cable & Wireless Communications Plc and its affiliates reserve the right to 
monitor all email communications through their networks to
ensure regulatory compliance.
 
Cable & Wireless Communications Plc is a company registered in England & Wales 
with number:
07130199 and offices located at 3rd Floor, 26 Red Lion Square, London WC1R 4HQ

Reply via email to