none
Silverlight plugIn unresponsive on google chrome.

    Question

  • Hi Friends,


                       I have a silver light application running on IE8  without any issue, but with Google chrome issue starts in the application, on debugging I noticed silverlight plugin becomes unresponsive. Upon googling I observed that SilverLight4 has resolved this issue, but this isn't true as I am using Silverlight v4.0 is there something I am missing.

    Further when a call is made to WCF service in the same applicaiton, I get error "No connection could be made because the target machine actively refused it  127.0.0.1:8000"

    Can some one please comment\share there opnion on this issue, I have spend couple of days on this with out any luck.

    Regards.

    Harish.

    Tuesday, July 26, 2011 1:54 AM

Answers

  • This is really strange. If all that logic is "hidden" in the service, then I don't understand why the client-side browser should affect the outcome.

    I can pretty much only recommend to do a more detailed analysis of what's going on. E.g. use Fiddler to look at the traffic that runs from your client to the service and back, and see what is different between IE and Chrome - maybe that gives a clue what may cause this.

    Wednesday, July 27, 2011 12:06 PM

All replies

  • Hi. When you say "debugging", do you mean when you step through your code? Chrome has a pretty aggressive detection mechanism for plug-in crashes/hangs that is triggered easily when you debug your code. If you don't run into these issues at runtime (without debugging), then there's nothing to worry about.

    Tuesday, July 26, 2011 2:09 AM
  • Hi,

                  Yes, thats true the plugin become unresponsive when I step thorugh the code.  Well, at run time the issue is different fow which I have to debug the below. Well the call from WCF is made to a windows service which report the below error.

    Message TDApp.Client.App 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.BrowserHttpWebRequest.InternalEndGetResponse(IAsyncResult asyncResult)

       at System.Net.Browser.BrowserHttpWebRequest.<>c__DisplayClass5.<EndGetResponse>b__4(Object sendState)

       at System.Net.Browser.AsyncHelper.<>c__DisplayClass4.<BeginOnUI>b__1(Object sendState)

       --- End of inner exception stack trace ---

       at System.Net.Browser.AsyncHelper.BeginOnUI(SendOrPostCallback beginMethod, Object state)

       at System.Net.Browser.BrowserHttpWebRequest.EndGetResponse(IAsyncResult asyncResult)

       at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteGetResponse(IAsyncResult result)

       --- End of inner exception stack trace ---

       at System.ServiceModel.DomainServices.Client.WebDomainClient`1.EndInvokeCore(IAsyncResult asyncResult)

       at System.ServiceModel.DomainServices.Client.DomainClient.EndInvoke(IAsyncResult asyncResult)

       at System.ServiceModel.DomainServices.Client.DomainContext.CompleteInvoke(IAsyncResult asyncResult)
    ---------------------------
    OK  
    ---------------------------
    \"><a:string>Documents/test/4/4.jpg_1.png</a:string></documentPath><originalDocumentPath>Documents/test/4.jpg</originalDocumentPath></ExtractItemResponse>" string

     

     

    ---------------------------

    ---------------------------
    Message TDApp.Client.App System.ServiceModel.CommunicationException ---> System.Net.WebException ---> System.Net.WebException

       at System.Net.Browser.BrowserHttpWebRequest.InternalBeginGetResponse(AsyncCallback callback, Object state)

       at System.Net.Browser.AsyncHelper.<>c__DisplayClassa.<BeginOnUI>b__7(Object sendState)

       --- End of inner exception stack trace ---

       at System.Net.Browser.AsyncHelper.BeginOnUI(BeginMethod beginMethod, AsyncCallback callback, Object state)

       at System.Net.Browser.BrowserHttpWebRequest.BeginGetResponse(AsyncCallback callback, Object state)

       at System.ServiceModel.Channels.HttpChannelFactory.HttpRequestChannel.HttpChannelAsyncRequest.CompleteSend(IAsyncResult result)

       --- End of inner exception stack trace ---

       at System.ServiceModel.DomainServices.Client.WebDomainClient`1.EndInvokeCore(IAsyncResult asyncResult)

       at System.ServiceModel.DomainServices.Client.DomainClient.EndInvoke(IAsyncResult asyncResult)

       at System.ServiceModel.DomainServices.Client.DomainContext.CompleteInvoke(IAsyncResult asyncResult)
    ---------------------------
    OK  
    ---------------------------

     

    Wednesday, July 27, 2011 1:16 AM
  • Yes, thats true the plugin become unresponsive when I step thorugh the code.

    Like I said, that is normal - just choose not to abort the plug-in and Chrome will lengthen the period until the next warning.

    the call from WCF is made to a windows service which report the below error.

    Are you saying that you call a Windows Service from your WCF service? Or are you calling a WCF service that is hosted inside a Windows Service from Silverlight?

    In the latter case, the issue most likely is that you don't provide a clientaccesspolicy.xml file in your self-hosted service. Take a look at the second post marked as answer here to find a solution then.

    Wednesday, July 27, 2011 1:47 AM
  • Hi Peter,

                Appreciate your prompt response. Well in my case  the former is true  (i.e.) a call is made to Windows Service(written in C++) from WCF service, and I get the error in a message box as below.

    [Service not available. Please contact AdminInvoke operation 'RIAServiceRequest' failed. The remote server returned an error: NotFound.]

    This is the case only with Chrome and not with IE7,8 and 9 version.

    Wednesday, July 27, 2011 5:10 AM
  • This is really strange. If all that logic is "hidden" in the service, then I don't understand why the client-side browser should affect the outcome.

    I can pretty much only recommend to do a more detailed analysis of what's going on. E.g. use Fiddler to look at the traffic that runs from your client to the service and back, and see what is different between IE and Chrome - maybe that gives a clue what may cause this.

    Wednesday, July 27, 2011 12:06 PM
  • Peter,

                                 Thanks for your suggestion and was engaged with someother issues and today as per your recommendaton I compared on Fiddler the request and response below is the comprasion.

    Line 12 of IE and line 105 of Chrome reffer to similar request and here is when I get the service not available issue on chrome.


    IE Request\Response.

    # Result Protocol Host URL Body Caching Content-Type Process Comments Custom 
    1 200 HTTP 10.96.9.153 /Localhost/ 3,735 no-cache  Expires: -1 text/html; charset=utf-8 iexplore:3136   
    2 304 HTTP 10.96.9.153 /Localhost/Silverlight.js 0   iexplore:3136   
    3 304 HTTP 10.96.9.153 /Localhost/ClientBin/Td.Client.xap 0   iexplore:3136   
    4 404 HTTP 10.96.9.153 /Localhost/images/Td.png 5,275 private   text/html; charset=utf-8 iexplore:3136   
    5 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 2,212 private   application/msbin1 iexplore:3136   
    6 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 2,212 private   application/msbin1 iexplore:3136   
    7 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 13,500 private   application/msbin1 iexplore:3136   
    8 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 46,409 private   application/msbin1 iexplore:3136   
    9 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 877 private   application/msbin1 iexplore:3136   
    10 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 620 private   application/msbin1 iexplore:3136   
    11 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 6,034 private   application/msbin1 iexplore:3136   
    12 200 HTTP 10.96.9.153 /Localhost/MimeTypeHandler.ashx?fileName=GreenBubbles.jpg&filePath=Documents/TdDB/2.jpg 6,406 private   application/x-octet-stream iexplore:3136  

     
    13 304 HTTP 10.96.9.153 /Localhost/Documents/TdDB/2/2.jpg_1.png 0   iexplore:3136   
    14 200 HTTP 10.96.9.153 /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 620 private   application/msbin1 iexplore:3136   

     

    Chrome Request\Response.

    90 200 HTTP localhost /Localhost/ 3,735 no-cache  Expires: -1 text/html; charset=utf-8 chrome:4472   
    91 302 HTTP go.microsoft.com /fwlink/?LinkId=161376 223 private  Expires: Thu, 18 Aug 2011 08:31:46 GMT text/html; charset=utf-8 chrome:4472   
    92 404 HTTP localhost /Localhost/images/Td.png 5,273 private   text/html; charset=utf-8 chrome:4472   
    93 404 HTTP localhost /favicon.ico 5,176 private   text/html; charset=utf-8 chrome:4472   
    94 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 2,212 private   application/msbin1 chrome:4472   
    95 200 HTTP CONNECT www.google.com:443 0   chrome:4472   
    96 502 HTTP yplteilnzx / 512  text/html; charset=UTF-8 chrome:4472   
    97 502 HTTP iwhjexdhwd / 512  text/html; charset=UTF-8 chrome:4472   
    98 502 HTTP deqsbssver / 512  text/html; charset=UTF-8 chrome:4472   
    99 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 2,212 private   application/msbin1 chrome:4472   
    100 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 13,500 private   application/msbin1 chrome:4472   
    101 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 46,409 private   application/msbin1 chrome:4472   
    102 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 822 private   application/msbin1 chrome:4472   
    103 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 620 private   application/msbin1 chrome:4472   
    104 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 5,956 private   application/msbin1 chrome:4472   
    105 200 HTTP localhost /Localhost/MimeTypeHandler.ashx?fileName=map.jpg&filePath=Documents/TdDB/4.jpg     11,489,274 private   application/x-octet-stream chrome:4472  
    106 200 HTTP localhost /Localhost/ClientBin/Td-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest 822 private   application/msbin1 chrome:4472   

    Thursday, August 18, 2011 4:43 AM
  • If you look at the requests, then you can see that both of them return successfully (code 200), so it's actually not a problem of the service (which is what I had doubted above). 

    A significant difference is the size of the result - it's only a few kbytes in the first request, but a whopping 11 mb in the second one, so it's probably a problem of running into some limitations regarding either the maximum response size or time limits. Or do you have requests for smaller files that also fail in Chrome?

    Thursday, August 18, 2011 4:57 AM
  • Well everything fails in chrome even(10kb) file, the above observations are based on random file selection. The operation preformed here is to download a file and save it to local disk.

    As you have mentioned "problem of running into some limitations either the xamimum response size or time limit " has it to do some setting with browser?

     

    Thursday, August 18, 2011 5:10 AM
  • No, that would have been an issue with Silverlight; but when you say it fails for small files also, that is not it.

    Let's take a step back please. Until now we were talking about an error when you call your WCF service from Silverlight. However, I just realized that the requests in Fiddler are not service calls, but calls to an ASP.NET http handler. Maybe we should talk about the setup and when, how and where the error occurs once again.

    Thursday, August 18, 2011 5:49 AM
  • Well the handler in silverlight invoke RIA services which in turn communicates with WCF. Upon further investigation I noticed a frequent Request/Response to RIA service is causing this issue. The RIA service version I have is 1.0 SP1, can  you please confirm if RIA support Chrome/Mozilla or is there anyother issue.

    Further if I keep the app open on Chrome for about 10mins I end up getting the below message.

    Service not available. Please contact AdminInvoke operation 'RIAServiceRequest' failed. The HTTP request to 'http://localhost:8560/ClientBin/TD-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest' has exceeded the allotted timeout. The time allotted to this operation may have been a portion of a longer timeout.

     

    Friday, August 19, 2011 7:11 AM
  • Yes, RIA services supports all browsers that are supported by Silverlight itself, including Chrome and Firefox.

    How do you do the calls the ASP.NET handlers that fail, from Silverlight?

    Friday, August 19, 2011 7:18 AM
  • The calls are by registering Eventhandlers from Silverlight client.

    Can you please let me now on the below - as to why this is causing when I keep the app open on Chrome for about 10mins I end up getting the below message.

    Service not available. Please contact AdminInvoke operation 'RIAServiceRequest' failed. The HTTP request to 'http://localhost:8560/ClientBin/TD-Client-Web-WCFDomainService.svc/binary/RIAServiceRequest' has exceeded the allotted timeout. The time allotted to this operation may have been a portion of a longer timeout.

    Friday, August 19, 2011 7:25 AM
  • Do you have a sample project that you can upload? I'm willing to take a look at it and see what's going on if you can.

    Apart from that I don't think I'll be able to get anywhere by talking about the problem - I just don't seem to get your setup. Sorry.

    Saturday, August 20, 2011 3:45 AM
  • Thanks for you help. Well the issue seems with recursive function call which make RIA request and after disabling the recursive call I am not getting this.

    Tuesday, August 23, 2011 5:21 AM
  • Hey, glad you finally figured it out. Sorry that I couldn't be of more help on this.

    Tuesday, August 23, 2011 6:43 AM