top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

Tomcat Threads busy

0 votes
548 views

When a request comes to tomcat and tomcat does not have any free thread available or all the threads are busy and request queue is also full then where I need to write the logic for redirect the request to some other server.

I have ConnectionRedirectionValve.java already written but in that file the request redirection logic is handled when threads are not sufficient at application level means application inside tomcat do not have any spare semaphore that is handled in this file.

Even though when tomcat does not have sufficient threads then I do not think the flow will move to ConnectionRedirectionValve.java So please suggest how to handle this

posted Jul 23, 2013 by anonymous

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

+1 vote

That logic needs to happen in another layer, in a load-balancer. Tomcat cannot do this on its own.

answer Jul 23, 2013 by anonymous
Similar Questions
+2 votes

I am working on Tomcat monitoring solution for a project and when it comes to monitoring 'Thread usage', I am wondering whether I should be comparing 'currentThreadCount' or 'currentThreadBusy' attribute against 'maxThread' to generate an alert.

Is currentThreadBusy the actual representation of the activeThread count ? If currentThreadCount increases when there is an increase in need of request processing threads and once the requests are processed, whether the currentThreadCount drops?

+1 vote

In tomcat does the no . of open sockets on http port (netstat -anlp|grep 8080) is it equal to number of threads in use in tomcat .
Actually I want to understand how & when I can say that the all threads in a tomcat are fully utilized that why it is responding slow.

0 votes

I heard the term "worker thread" and other types of threads such as "system thread" and "user thread".
For me a thread is nothing but a lite weight process and multi-threaded design is chosen for a software development when there are multiple task in the application/system and those tasks can be executed independently.
I want to know when these different terms are used like worker thread, user thread and system thread ?

...