Henri Gomez said:
> Henri Gomez a écrit :
>>> Nope since you don't have to just test at protocol level but also on
>>> higher level, for instance check the full chain, up to servlet
>>> handling.
>>>
>>>> It's easy to simulate this behavior by sending a STOP signal to
>>>> Tomcat.
>>>>
>>>> I've also attached a log from mod_jk showing the problem.  I marked
>>>> the
>>>> point at which processing in mod_jk stopped until I sent a CONT
>>>> signal to
>>>> tomcat.
>>>>
>>>> Does mod_jk2 have this same problem?  Is there any interest in fixing
>>>> this? Does anyone have a workaround for this issue?
>>>
>>> Well, if you have a hung tomcat, you're probably allready in serious
>>> trouble.

No, actually in my case I wasn't.  I had two Tomcats running, as one was
prone to locking up due to a JVM or application bug.  With a 50-50 load
distribution between two Tomcats, this left me with 1/2 of the requests
getting stuck and clients waiting forever and tying up Apache processes. 
Eventually, a DOS will be the result if action is not taken in time.  If
mod_jk noticed it wasn't really alive, this wouldn't be an issue at all.

>>> Anyway, if we add stuff like time-out in ajp request, you could be
>>> stuck with long running servlets. Also jk read request in a blocking
>>> mode for performance and adding timeout here is not an option.

Agreed that we wouldn't want a timeout normally to handle normal long
running servlet processes, but if there was a PING/PONG added to the
protocol there should be a timeout to prevent the above situation.

>> When I worked on ajp13++ (ajp14) protocol, I added a more secure auth
>> mecanism at connection time.
>>
>> Since there is a bidirectionnal communication, jk could detect that
>> even if the connection is open, the remote didn't respond and so fall
>> back to the next in cluster configuration.
>>
>> But on allready established connections, the problem persist.
>>
>> Or we should add a PING/PONG before sending any request to tomcat.
>>
>> It could be done as optional but I work on it only if many users make
>> such requirements
>
> if many users ask for such feature ;)

Well, you've got one so far.  ;-)  Adding a configurable option to have
mod_jk verify (PING/PONG) that Tomcat is actually responding before using
the connection would solve the problem and I can't imagine that it would
add a lot of complexity to the code as well.  If I wasn't so rusty with my
C programming and had some spare time, I would offer to help code it up. 
;-)  In any case, I'll be more than happy to help test.

Thanks,
Dave



-Dave

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to