0
votes

If i leave my silverlight application for 10 minutes or so then call a soap method i get the following stack trace:

{System.ServiceModel.CommunicationException: The remote server returned an error: NotFound. ---> System.Net.WebException: The remote server returned an error: NotFound. ---> System.Net.WebException: The remote server returned an error: NotFound. at System.Net.Browser.ClientHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult) at System.Net.Browser.ClientHttpWebRequest.<>c_DisplayClass5.b_4(Object sendState) at System.Net.Browser.AsyncHelper.<>c_DisplayClass2.b_0(Object sendState) --- End of inner exception stack trace --- at System.Net.Browser.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state) at System.Net.Browser.ClientHttpWebRequest.EndGetResponse(IAsyncResult asyncResult) at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result) --- End of inner exception stack trace --- at System.ServiceModel.AsyncResult.End[TAsyncResult](IAsyncResult result) at System.ServiceModel.Channels.ServiceChannel.EndCall(String action, Object[] outs, IAsyncResult result) at System.ServiceModel.ClientBase1.ChannelBase1.EndInvoke(String methodName, Object[] args, IAsyncResult result) at BlueForums.Blue.BlueClient.BlueClientChannel.EndThreadViewIncrement(IAsyncResult result) at BlueForums.Blue.BlueClient.BlueForums.Blue.IBlue.EndThreadViewIncrement(IAsyncResult result) at BlueForums.Blue.BlueClient.OnEndThreadViewIncrement(IAsyncResult result) at System.ServiceModel.ClientBase`1.OnAsyncCallCompleted(IAsyncResult result)}

I've tried attaching my own service behavior to catch the messages and it looks like silverlight it actually calling the server at all.

any one got any ideas?

3
Do you have your own ServiceHost? Could be a timeout issue.decyclone
It is hosted in IIS, so im pritty sure it looks after the servicehostJonathan D
I have wcf tracing turned on also whish isnt showing any calls been made at allJonathan D

3 Answers

0
votes

Unfortunately, because of Silverlight sandboxing you will get a NotFound error for ANY error that occurs w.r.t your web service. So, if you want to know what the error really is you will have to turn on web service tracing.

0
votes

I found fiddler to be of good help, learn how to use it, it saves you a lot of time

0
votes

I have had this problem before, it seems to only occur with IE.

If the service has to timeout, drop connection, recycle (IIS recycles the service when it is not being accessed), or just lose connectivity then IE will no longer try to contact the WCF service, even if you restart the service.

Recently i started using IE9 RC, and this behavior seems to have been fixed. Anyway if the silverlight app ever tries to contact the server, and it is unavailable for what ever reason, then every call from that point on will fail, not only fail, but IE wont even try to contact your service.

Hence why logging in WCF wont show a call at all, in firefox, use firebug, and you will see the silverlight app trying to make the call after your 10 minutes or so.

Try it out.