<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.iis.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:cs="http://blogs.iis.net/"><channel><title>IIS7 - Publishing</title><link>http://forums.iis.net/1045.aspx</link><description>Discussion around anything related to publishing content on the IIS 7 web platform</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: Isssue with replacing assembilies in bin folder during deploy to 24 x IIS7 servers</title><link>http://forums.iis.net/thread/1905922.aspx</link><pubDate>Fri, 05 Jun 2009 12:17:05 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1905922</guid><dc:creator>thewebhostingdir</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1905922.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1045&amp;PostID=1905922</wfw:commentRss><description>&lt;p&gt;&amp;nbsp;If I were you, I would have used the first option. Taking website down for 1 minute for updating components wont give any issues.&lt;br /&gt;&lt;/p&gt;</description></item><item><title>Isssue with replacing assembilies in bin folder during deploy to 24 x IIS7 servers</title><link>http://forums.iis.net/thread/1904052.aspx</link><pubDate>Mon, 18 May 2009 10:11:56 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1904052</guid><dc:creator>MattDuguid</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1904052.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1045&amp;PostID=1904052</wfw:commentRss><description>&lt;p&gt;We deploy twice a day to 24 front end web servers. We&amp;nbsp;are sometimes seeing an issue when copying assemblies into the bin folder under our application. We think that the new assemblies are trying to be read before they have had a chance to be written to disk completely.&lt;/p&gt;
&lt;p&gt;There are a few posts/blogs on the web with people having similar issues. Two workarounds I have read include the following,&lt;/p&gt;
&lt;p&gt;Idea 1&lt;br /&gt;You can&amp;nbsp;take&amp;nbsp;an AppDomain offline by simply placing a file called app_offline.htm into the root directory of the application. Once its&amp;nbsp;offline&amp;nbsp;all locks on files are released and this would allow them to be updated. After the file app_offline.htm is removed or renamed,&amp;nbsp;the next time a request hits the app the appdomain is spun up again. The caveats with this&amp;nbsp;are that it only works for ASP.NET content and requires some downtime.&lt;/p&gt;
&lt;p&gt;Idea 2&lt;br /&gt;Keep the assemblies unlikely to change in bin and put ones that will change regularly into a sub-folder of bin and name the folder according to the date and time of deploy (eg: bin\20090517-1400). Setup the web.config with the following,&lt;/p&gt;
&lt;p&gt;&amp;lt;runtime&amp;gt;&lt;br /&gt;&amp;lt;assemblyBinding xmlns=&amp;quot;urn:schemas-microsoft-com:asm.v1&amp;quot;&amp;gt;&lt;br /&gt;&amp;lt;probing privatePath=&amp;quot;bin;bin\20090517-1400;&amp;quot; /&amp;gt;&lt;br /&gt;&amp;lt;/assemblyBinding&amp;gt;&lt;br /&gt;&amp;lt;/runtime&amp;gt;&lt;/p&gt;
&lt;p&gt;To update assemblies, upload them into a new sub-folder in bin with a name corresponding to the current date (bin\20090518-1555). After the upload is complete, upload the web.config with a change to the sub-folder name. The app re-starts and picks up the new assemblies and forgets about the old sub-folder assemblies which can be left or deleted. Apparently this works and has the added benefit of speeding up the app start since the sub-folder assemblies are ignored until needed. &lt;br /&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;So&amp;nbsp;the question is...what is the best practice and supported method from Microsoft for achieving what we need? Is it one of the methods above or is there a better way?&lt;/strong&gt;&lt;/p&gt;</description></item></channel></rss>