8
I have an application developed in C# that consumes a webservice also in C#.
In some cases (not always and not everywhere/customers) when consuming the webservice i get the following error:
Unable to connect to remote server
A connection attempt failed because the connected component did not respond correctly after a period of time or the established connection failed because the connected host did not answer meuip:80
I’ve had problems with another error (that burst on the same line) that was:
Bug description: Remote name could not be solved: 'webservices.meusite.com.br'
But I was able to solve it only by repeating the attempt in case of error.
stacktrace shows the following:
em System.Net.HttpWebRequest.GetRequestStream(TransportContext& context) em System.Net.HttpWebRequest.GetRequestStream() em System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String methodName, Object[] parameters) em Updater.WebServ.Servico.Metodo(Int32 Id) em Updater.TelaPrincipal.btTeste_click(Object sender, EventArgs e)
The most intriguing of all is that no matter how many times I try here, it never fails. The problem is only in some places.
What could be causing this?
What is the Statuscode returned in Sponse? Statuscode indicates if the problem is on the client or server.
– Renatto Machado
I believe it is problem in the operation Timeout, already checked the connection of its customers?
– Tobias Mesquita
@Tobymosque The connection I tested is pretty much the same as mine here.
– Jéf Bueno
@Renattomachado Excuse the ignorance, but where I see the Statuscode?
– Jéf Bueno
@Jéfersontas here I have an application that also makes some web accesses, and I have problems when the connection is 3G having to reconnect the modem so that it can work the service. Isn’t that the case? Your customers' web connection is done in what way?
– Andrew Alex
@Andrewalex ADSL, the two I tested this morning had good connections. But this may have been caused by instabilities or something then.
– Jéf Bueno
Statuscode is one of the properties of your Sponse. You are using Httpclient to request?
– Renatto Machado
@Jéfersontavares Does this depend a lot on the types of operations existing in your Webservice and the technology applied in Webservice, Cvoce uses same or WCF Webservices? in your contract there is some.
– Julio Borges
@Julioborges, it should be timeout then, because the information I get is small strings. For the record, I use webservices, not WCF. And, as I mentioned above, the amount of data transmitted is very small.
– Jéf Bueno
since after a few attempts you succeed, the problem is in the internet connection of your customers that is not of good quality. A software that responds properly on multiple machines cannot be the cause of the lack of response in other.
– Claudio Ferreira