Jump to content
Sign in to follow this  
mendopablo

CIAPI.CS locks on requests

Recommended Posts

CIAPI.CS freezes the Main Thread on:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/ThrottedRequestQueue.cs.orig#L135

Looking at other threads I found one waiting at:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/RequestController.cs#L196

This happens randomly but more frecuently when we make two or more requests in a short period of time. I think that if any of the webrequests fails then the lock is never free.

Share this post


Link to post
Guest sky.sanders

I think that we have isolated this issue and it revolves around the fact that phone7/silverlight have a hard coded maximum of 6 http connections. It manages multiple connection requests by queuing them. The streaming implementation requires more than one connection for each stream. Opening multiple streams quickly uses up this quota of connections and may leave your rpc request hanging in limbo within microsoft’s code.

For phone7 I have implemented a hard cap of 2 streams, this leaves 2 connections available to service rpc calls.

I apologize but for phone/silverlight clients will require more attention to connection management. I is not possible to open several streams.

Share this post


Link to post
Guest mrdavidlaing

CIAPI.CS freezes the Main Thread on:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/ThrottedRequestQueue.cs.orig#L135

Looking at other threads I found one waiting at:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/RequestController.cs#L196

This happens randomly but more frecuently when we make two or more requests in a short period of time. I think that if any of the webrequests fails then the lock is never free.

We’re investigating; but pinpointing the cause of the error is going to be tricky given that it happens “randomly”.

Could you create a sample app or unit test that shows the error occuring please?

Share this post


Link to post
Guest mrdavidlaing

CIAPI.CS freezes the Main Thread on:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/ThrottedRequestQueue.cs.orig#L135

Looking at other threads I found one waiting at:https://github.com/cityindex/CIAPI.CS/blob/master/src/JsonClient/RequestController.cs#L196

This happens randomly but more frecuently when we make two or more requests in a short period of time. I think that if any of the webrequests fails then the lock is never free.

 

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
×