WCF: PollingDuplex Exception Preventing Production Deployment RRS feed

  • Question

  • Hello

     We are currently using PollingDuplex binding in WCF to do Pub-Sub with Silverlight 3.  We are doing asyncronous messaging using a BeginSend() / EndSend() model.

    We have a serious problem with out WCF client channel / back channel, in that a call to EndSend() on the back channel of our SessionManager console app that our Silverlight client connects to is randomly throwing an InvalidOperationException: Collection was modified.

    Now we know what this exception means, but its been thrown from within the WCF EndSend() method so we have no idea what the cause is.  We are using Net.Tcp binding between our other services and we don't have this issue.

    It does seem that this problem occours more frequently when messages are sent rapidly at high frequency. We have gotten smarter and more efficient with our messaging but the issue has not gone away. Its a problem.

    We are considering falling back on sockets for out Silverlight communications...but would rather not.

    Has anyone had this issue and what can be done about it?  Is this a PollingDuplex binding bug?




    Sunday, December 20, 2009 6:19 PM

All replies

  • can you quickly verify Collection Type for the proxy generation code.

    Sunday, December 20, 2009 11:38 PM
  •  Ah, I don't know what you mean...

     We are self hosting by the way, not IIS hosting.

    Monday, December 21, 2009 12:18 AM
  • Hi,

    It looks like when the asyncronous call comes back and tries to update the data but find that the data has been changed. It would be more helpful to figure out the problem if you can post some test code.

    Thanks and Merry Christmas.

    Friday, December 25, 2009 12:11 AM