Setting Up Request Timeout for HTML5 Instance

Origam HTML5 is usually set up behind a proxy server. Either behind IIS or NGINX. Depending on the setup, the long running requests might end up with a timeout error from the proxy server.

#IIS

There are two options how to prevent timeout problem.

  1. Set hosting model to InProcess.
<configuration>
  <location path="." inheritInChildApplications="false">
    <system.webServer>
      <handlers>
        <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      </handlers>
      <aspNetCore processPath="dotnet" arguments=".\Origam.ServerCore.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="InProcess" />
    </system.webServer>
  </location>
</configuration>
  1. Set requestTimeout property - by default the value is 2 minutes.
<configuration>
  <location path="." inheritInChildApplications="false">
    <system.webServer>
      <handlers>
        <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      </handlers>
      <aspNetCore requestTimeout="00:06:00" processPath="dotnet" arguments=".\Origam.ServerCore.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="OutOfProcess" />
    </system.webServer>
  </location>
</configuration>

#NGINX

server {

proxy_read_timeout 360;
proxy_connect_timeout 360;
proxy_send_timeout 360;

}

The values are in seconds. The timeout is set to 6 minutes in this example.

Hi Jiří,

I have the configuration set up as above:

server {
        listen 80;
        listen [::]:80;

        access_log /var/log/nginx/reverse-access.log;
        error_log /var/log/nginx/reverse-error.log;

		proxy_read_timeout 360;
		proxy_connect_timeout 360;
		proxy_send_timeout 360;
		client_max_body_size 20M;
    ...
}

but the request timeouts after one minute.

What could be wrong?

Thank you,
David

Hi David,
Are you sure that you are using the nginx with this configuration ?