Tomcat takes the bill

I have the following question about Tomcat acceptCount .
It says:

The maximum queue length for incoming connection requests when all request processing threads are used. Any requests received when the queue is full will be denied. The default value is 10.

I am not sure how this works. I mean, I know that there is a separate TCP queue that determines how many connections can come if I put acceptCount at the application level, for example. 30000, doesn’t matter?
I mean that this configuration is not useful.

I'm right?

+7
source share
2 answers

This is a direct pass to the backlog parameter of the ServerSocket constructor. The idea is that the OS can support incoming connections, even if they cannot be processed immediately. This is only useful if you have multiple traffic and fast processing times.

+7
source

Yes, it can really help. I saw some java application with quite a lot of traffic (tens of megabits per second). At some point, application responses became very slow, and after some research, I decided to increase the acceptcount parameter in server.xml. And it really helped, the problem disappeared.

0
source

All Articles