tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Castilla | thin(k)design" ...@thin-k-design.com>
Subject Crash in http connector random once a day
Date Thu, 14 Mar 2019 10:12:33 GMT
Hi,

I have long searched and haven't found any real hint how to solve my
problem, so I am adressing you.

Here are my specifications:

Server version:        Apache Tomcat/8.5.15
Server built:          May 5 2017 11:03:04 UTC
Server number:         8.5.15.0
OS Name:               Windows Server 2012
OS Version:            6.2
Architecture:          amd64
Java Home:             C:\Program Files\Java\jre7
JVM Version:           1.7.0_25-b17
JVM Vendor:            Oracle Corporation

The tomcat connector I am using has no custom configuration:

<Connector port="8080" redirectPort="8443" protocol="HTTP/1.1"/>

I have a PHP Javabridge app (runs PHP CGI to access JAVA functions)
running on tomcat and it's beeing accessed solely through localhost
from other PHP scripts running on IIS. It goes as follows:

1. Request sent to IIS
2. Run PHP on IIS, process the request and delegates a part of the
processing to tomcat
3. Access tomcat through HTTP on localhost:8080 and wait maximum 60s
for the response, retry up to 3 times
4. Run PHP on tomcat, process the request and send data back to the
original PHP process on IIS (on 2.)
5. On IIS read the response from tomcat, process it and send a
response to the original request (on 1.)

For 99% of the time it goes well, we have around 500+ requests beeing
succesfully processed. BUT aprox. once a day there are around 4
requests to tomcat within 3 minutes or so that aren't receiving any
response at all (I have setup a 60s timeout in the IIS PHP process,
usually the tomcat process takes up to 10s to respond).

The strange thing is, those failed requests with no response are
logged in the tomcat access logs with a 500 http connection error all
at the same time (although they begun with 1-2 min difference) and
after 8 to 24 hours (the URL is alway unique, so I know for sure).

In the JAVA logs I can see a "java.net.SocketException: Connection
reset", which is logical, as the PHP process on IIS closed the
connection after the 60s timeout. I tried to set this timeout to
infinite, with the result that the PHP process on IIS waited between 8
and 24 hours, only to get a 500 from tomcat. This time I got in the
JAVA logs a "java.net.SocketException: Connection reset by peer"
(notice the difference "by peer").

I hope I described my problem accurate enough. I'm out of ideas and
I'm grateful for any insight!

Regards,
Daniel

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message