I'm using a Web Service call that reads emails, when reading 240 emails it works perfect, but when it's more than 240 emails, I get the following error:
The remote server returned an unexpected response: (524) Origin Time-out.
In the client's web.config it is defined as follows:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="ServicioWebLecturaCorreoSoap" />
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://webservice.prueba.cl/ServicioWeb.asmx"
binding="basicHttpBinding" bindingConfiguration="ServicioWebLecturaCorreoSoap"
contract="ServicioWebClienteLeeCorreo.ServicioWebLecturaCorreoSoap"
name="ServicioWebLecturaCorreoSoap" />
</client>
</system.serviceModel>
In the web.config of the Web Service it is:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="ServicioWebLecturaCorreoSoap" closeTimeout="00:30:00"
openTimeout="00:30:00" receiveTimeout="00:30:00" sendTimeout="00:30:00"
allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
maxBufferSize="2147483647" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647"
messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
useDefaultWebProxy="true">
<readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647"
maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
<security mode="None">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="" />
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
</binding>
</basicHttpBinding>
</bindings>
</system.serviceModel>
From the client I call it like this:
string stringconeccion = "bla bla bla";
ServicioWebClienteLeeCorreo.ServicioWebLecturaCorreoSoapClient servicio = new ServicioWebClienteLeeCorreo.ServicioWebLecturaCorreoSoapClient();
lbMensaje.Text = "Buscando ...";
var source = new BindingSource();
var list = servicio.Obtieneadjunto(txtHostCorreo.Text, txtUsuario.Text, txtPassword.Text, stringconeccion);
The error I get when I use the Web Service production site, but when I use one from my computer (localhost), there's no problem.
I would like to know how to repair the error, what parameter should I place or perhaps increase some range of timeout . I would appreciate your help.