<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
<title>Snipplr - bryanlyman</title>
<link>http://snipplr.com/users/bryanlyman/tags/thread</link>
<description>Recent snippets posted on Snipplr.com</description>
<language>en-us</language>
<pubDate>Sun, 26 May 2013 12:22:43 GMT</pubDate>
<item>
<title>(C#) Asynchronous ASP.Net Pages, AJAX Helper, WebRequest Passthrough</title>
<link>http://snipplr.com/view/28142/asynchronous-aspnet-pages-ajax-helper-webrequest-passthrough/</link>
<description><![CDATA[ <p>.net 3.0+, Ajax calls allow for true asynchronous communication through a browser. You may not notice it until you have a server call that takes awhile, but just because AJAX is allowing it, that doesn't mean the server is acting in a truly asynchronous manner. By default aspx pages will asynchronously allow multiple calls to the same session, however, a thread-lock is placed on each subsequent call so that each incoming request must wait for the previous to finish before the response stream can be accessed. This is a nice protection measure to keep a page programmer from ripping their hair out because of multi-threading data access issues and dead-lock scenarios; but it is inversely annoying to one trying to allow asynchronicity. The solution to allow true multi-threaded asynchronous behavior isn't an easy one, but the following code is a step in the right direction. The first thing you should know is that to make a page act asynchronously is to set the "Async" attribute in the page directive of the aspx page being called </p> ]]></description>
<pubDate>Wed, 10 Feb 2010 16:21:15 GMT</pubDate>
<guid>http://snipplr.com/view/28142/asynchronous-aspnet-pages-ajax-helper-webrequest-passthrough/</guid>
</item>
</channel>
</rss>