Page 1 of 1

Timeout sending the file

Posted: Tue Jul 15, 2014 4:02 pm
by lp_inside
Hello,

when trying to upload a file having size bigger than 50MB approximately the browser displays the following error message: "Timeout sending the file: perhaps your browser does not send files correctly, your session has expired, or there was a server error. Please try again."

Is there a way to remove this limitation?
Thanks a lot!

Re: Timeout sending the file

Posted: Fri Jul 18, 2014 7:31 am
by car031
It seems your connection is really slow sint it is unusual to get timeout for just 50MB.
However you can change the upload timeout by locating this section in your WEB-INF/web.xml file:

<context-param>
<!-- Timeout used when uploading files (milliseconds) -->
<param-name>noDataTimeout</param-name>
<param-value>60000</param-value>
</context-param>

Re: Timeout sending the file

Posted: Thu Aug 28, 2014 9:28 am
by lp_inside
Hi,
thank you very much for the reply! :)
I've tried to change the configuration to:

<context-param>
<!-- Timeout used when uploading files (milliseconds) -->
<param-name>noDataTimeout</param-name>
<param-value>180000</param-value>
</context-param>

but unfortunately it seems that I still get the same error after 60 seconds instead of 180; I've tried to undeply and deploy the WAR archive again (I'm using Glassfish v.3.1.2.2) and I've also tried to update the gwtupload library (from v. 0.6.6 to 1.0.1) but I still get the same error...am I missing something?
Thanks again!

Re: Timeout sending the file

Posted: Thu Aug 28, 2014 9:49 am
by mmeschieri
Perhaps Glassfigh is ignoting that context parameter, i suggest you to use Tomcat

Re: Timeout sending the file

Posted: Fri Aug 29, 2014 11:17 am
by lp_inside
Hi,
thank you for the suggestion but unfortunately I can only use Glassfish in my environment.
I even tried to set that specific param with the Glassfish set-web-context-param command but I still get the same error after 60s. At this point I was wondering if there is a way to hardcode this parameter in some Java class or other resource, I mean instead of getting it from the web.xml file? Thanks...! :)

Re: Timeout sending the file

Posted: Fri Aug 29, 2014 2:46 pm
by agaspa
Have you tried to change the session timeout?
At the same web.xml file there is another parameter named called session-timeout

Code: Select all

  <session-config>
    <session-timeout>30</session-timeout>
  </session-config>
Another thing that might affect is the maximum size of the file.
If I remember well, in LogicalDOC the default maximum file size is fixed at 10 MB

Change this value in context.properties (when Tomcat is stopped)

Code: Select all

upload.maxsize=2000
or directly from the GUI using the path below:
Administration -> Settings -> GUI Settings -> Upload max. size

Alex

Re: Timeout sending the file

Posted: Mon Sep 01, 2014 1:47 pm
by lp_inside
Hi,
thanks for the reply! I did already change the upload.maxsize since I was getting another error about the max upload size and that change worked! I was then able to upload files having size >10MB.
Unfortunately now if I try to upload files having size > 50MB I still get the timeout error; I changed the configuration you suggested to:
<session-config>
<session-timeout>180</session-timeout>
</session-config>
I then reloaded the web application and restarted glassfish but I still get the same timeout error after 60s...! :(
So I was wondering if is there another way to change this parameter? Thanks!

Re: Timeout sending the file

Posted: Thu Sep 04, 2014 8:18 am
by agaspa
Which version of Glassfish are you using?
On what operating system?
What is your version of Java?

Re: Timeout sending the file

Posted: Thu Sep 04, 2014 3:44 pm
by lp_inside
Hi,
Glassfish: 3.1.2.2
OS: Red Hat 5.6
Java: 1.7.0_51