c# - Async programming against non-async services -



c# - Async programming against non-async services -

this past year we've been working on new web app calls our company's existing service layer.

we made decision wrap of our service oriented calls our own service layer (which i'll refer our web-service layer) details of services utilize (we'll move new api @ point in future) hidden web layer itself.

we decided of our web-service layer methods homecoming task<t>.

as stands, underlying services phone call not async , there concerns our web-service layer max out available threads , cause problems when have big volume of users.

i'm looking information, 1 way or other, farther understand how our decision homecoming task<t> impact our site , whether or not need consider changing our homecoming types.

we'll moving vs2012 @ point right we're using vs2010 , not using async , await.

as stands, underlying services phone call not async , there concerns our web-service layer max out available threads , cause problems when have big volume of users.

yes that's should concerned with. recommend doing if have real asynchronous methods. wrapping blocking synchronous methods async api worse calling synchronous methods straight consuming code. in asp.net application benefit asynchronous calls if underlying api relying on i/o completion ports. otherwise it's waste of resource.

the useful scenario in if methods called in parallel instead of sequentially. possible different methods not connected between them. in case indeed wrap sync methods in async tasks.

c# asp.net asynchronous threadpool

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -