tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From William Campillo <>
Subject Connector Configuration attributes
Date Mon, 18 Sep 2006 18:16:22 GMT

I was having a problem uploading files to a Database via Java applications
in Tomcat. I solved the problem by changing the connectionTimeout Connector
configuration attribute to 60000. But I have some questions:
   1) Is there a resource that provides more detail for Connector
   configuration attributes, like connectionTimeout, than the resources
   I've used ( and
   "Apache Tomcat 5, Chopra,")?
   2) Assuming there's a tradeoff in modifying connectionTimeout (and that
   I might want to go greater than 60000), what do I need to watch out for?
   3) Can I specify the behavior of the disableUploadTimeout configuration

   Read no further, or, here are the details of the issue, if you're

   I am running Apache Tomcat v5.5.12 behind an Apache (v2) Reverse Proxy
   server. I'm also running a SunONE Application Server behind the same RP.

   Some of the Servlets/Applications on either Tomcat or SunONE have
   features to upload data into databases. When the data is sufficiently
   large (about 2.5MB), the upload fails and I get an error:

         Proxy Error

         The proxy server received an invalid response from an upstream

         The proxy server could not handle the request POST

         Reason: Error reading from remote server

         (Embedded image moved to file: pic22348.jpg)
         Apache/2.0.55 (Unix) Server at j2ee.<test domain>.com Port 80

   The RP intercepts any "j2ee" URL and redirects it to the proper
   server-port (tomcat or SunONE) based on the URI.

   The error occurs consistently at just over 30sec after initiating the
   On my RP server, I tried modifying httpd.conf, putting the following
   into the Location Directive:
         SetEnv force-proxy-request-1.0 1
         SetEnv proxy-nokeepalive 1

         (this per

   Didn't work. Also tried putting those lines in the appropriate
   VirtualHost directive, instead. No good.

   I tried changing "KeepAliveTimeout 15" to "KeepAliveTimeout 60", no luck
   there either.

   References to the error I'm getting (through google and elsewhere) have
   not been particularly helpful.

   Finally, I focused on two attributes of the Connector configuration in
   server.xml: connectionTimeout and disableUploadTimeout. The former was
   set to 20000 and the latter to "true". Changing connectionTimeout to 0,
   or even to 60000 solved the problem.

   Reference shows
   the default value of  connectionTimeout is 60000. "Apache Tomcat 5,
   Chopra," shows it as either 20000 or 60000 depending on where you
   look. I assume that means that the value if not explicitly set is 60000,
   but that the default file explicitly sets it at 20000.  The
   disableUploadTimeout attribute is described on the above website thusly:
   " This flag allows the servlet container to use a different, longer
   connection timeout while a servlet is being executed, which in the end
   allows either the servlet a longer amount of time to complete its
   execution, or a longer timeout during data upload. If not specified,
   this attribute is set to "false"." It does not specify whether there is
   a different timeout attribute that is used, nor how much longer it will
   wait. Either I overlooked it, or Chopra doesn't mention

William J. "Bill" Campillo
System Administrator, Senior Professional
UNIX System and Web Administration
CSC(GIS/Glass House) for Raytheon Missile Systems
Tucson, AZ
520.545-6469 (office)
520.247.5892 (mobile)


This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery. NOTE: Regardless of content, this e-mail shall not operate to
bind CSC to any order or other contract unless pursuant to explicit written
agreement or government initiative expressly permitting the use of e-mail
for such purpose.

View raw message