You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Jerry Malcolm <te...@malcolms.com> on 2016/06/04 18:00:22 UTC
mod_jk resubmitting request to Tomcat
I am calling a JSP to start a fairly long-running process in Tomcat.
I'm not using the page response data. The JSP is simply a way to
initiate the process. The JSP simply returns "OK" or "RC=". However,
mod_jk gets impatient, and after about 5 minutes, it decides to send the
request to Tomcat again, which kicks off another instance of the
back-end process (obviously not what I want). Following is from the
mod_jk log:
>>> can't receive the response message from tomcat, network problems or
tomcat is down (127.0.0.1:8009), err=-60
>>> Tomcat is down or refused connection. No response has been sent to
the client (yet)
>>> receiving from tomcat failed, recoverable operation attempt=0
>>> sending request to tomcat failed, recoverable operation attempt=1
How can I tell mod_jk to be more patient for this request and not to
resubmit it?
Thanks.
Jerry
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org
Re: mod_jk resubmitting request to Tomcat
Posted by Anthony Biacco <ab...@handll.com>.
On Sat, Jun 4, 2016 at 12:00 PM, Jerry Malcolm <te...@malcolms.com>
wrote:
> I am calling a JSP to start a fairly long-running process in Tomcat. I'm
> not using the page response data. The JSP is simply a way to initiate the
> process. The JSP simply returns "OK" or "RC=". However, mod_jk gets
> impatient, and after about 5 minutes, it decides to send the request to
> Tomcat again, which kicks off another instance of the back-end process
> (obviously not what I want). Following is from the mod_jk log:
>
> >>> can't receive the response message from tomcat, network problems or
> tomcat is down (127.0.0.1:8009), err=-60
> >>> Tomcat is down or refused connection. No response has been sent to the
> client (yet)
> >>> receiving from tomcat failed, recoverable operation attempt=0
> >>> sending request to tomcat failed, recoverable operation attempt=1
>
> How can I tell mod_jk to be more patient for this request and not to
> resubmit it?
>
you probably have the reply_timeout on the worker set too low.
https://tomcat.apache.org/connectors-doc/common_howto/timeouts.html
-Tony
> Thanks.
>
> Jerry
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>
Re: mod_jk resubmitting request to Tomcat
Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jerry,
On 6/4/16 2:00 PM, Jerry Malcolm wrote:
> I am calling a JSP to start a fairly long-running process in
> Tomcat. I'm not using the page response data. The JSP is simply a
> way to initiate the process. The JSP simply returns "OK" or "RC=".
> However, mod_jk gets impatient, and after about 5 minutes, it
> decides to send the request to Tomcat again, which kicks off
> another instance of the back-end process (obviously not what I
> want). Following is from the mod_jk log:
>
>>>> can't receive the response message from tomcat, network
>>>> problems or
> tomcat is down (127.0.0.1:8009), err=-60
>>>> Tomcat is down or refused connection. No response has been
>>>> sent to
> the client (yet)
>>>> receiving from tomcat failed, recoverable operation
>>>> attempt=0 sending request to tomcat failed, recoverable
>>>> operation attempt=1
>
> How can I tell mod_jk to be more patient for this request and not
> to resubmit it?
Maybe tell mod_jk which requests are okay to retry and how many times?
Better yet, change your JSP to launch the long-running process using a
thread executor and return a complete response to the client. Then
there's no problem.
- -chris
-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - http://gpgtools.org
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iEYEARECAAYFAldVyxgACgkQ9CaO5/Lv0PCXiwCfWcICVhfEZORzWOzPTXmlWaHO
2SsAoLkM6pMyCArTHA4WZhQzeLF5TQSC
=U1Uf
-----END PGP SIGNATURE-----
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org