tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mladen Turk" <>
Subject [proposal] add the apr_queue mechanism to apr_socket
Date Wed, 22 Jan 2003 20:32:56 GMT

One more...

Here is the scenario:

If TC instance is too busy or reached the connection limit the next
connection is refused, causing entire worker to switch to the error
state. This isn't very smart (at least for threaded servers).
I propose that we use the apr_queue to solve that.
The socket will be pushed to the queue, when successfully connected, and
pop when finished.
If we reach the connection limit the next one will block until the any
of the active one finishes (releasing space in the queue).
Also, if the connection is refused and we have some sockets in the queue
(meaning the TC is busy responding), we'll block untill the connection
is accomplished or timed-out.

If there is a connection error caused by the TC's fault, the returned
error from freed one will cause the entire worker to go to the error


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message