Martin Kulov's Blog

VSTS, Oslo, INETA, ASP.NET, Debugging .NET Applications, Tips and Tricks

February 04, 2010

Speed up ASP.NET compilation

If you do ASP.NET development on a daily basis, you know that any change in bin, App_Code folder as well global.asax invalidates all compiled assemblies and initiates a full recompile. This can be very tedious process, especially if you are changing these files a lot during development.

Microsoft introduces a new web.config setting that prevents full recompile in such situations. The setting is added through a QFE (patch) to Windows XP and Windows 2003, Vista and Windows 2008, and is included in Windows 7 by default.

You can enable this optimized setting by the following section:

<compilation optimizeCompilations="true">

Read the complete article to find out the possible issues you may run into.

I wouldn’t recommend this setting for production web sites as it can introduce runtime errors. Even if you web site is so big that it takes 10 min to recompile it all, chances that you are running in web farm environment are pretty big these days. Shutting down one of the web farm servers until the compilation process completes, shouldn’t be such an issue. After all how many times are you going to apply updates on the production server? In situations where you are not using your production server for staging and test environment, updates will be most probably applied once per week even less.

In development environment this switch can change your life. Again, keep in mind the possible implications caused by this setting as described in the article above.

Bonus tip: In ProPeople we are also using RAMDisk to redirect ASP.NET temporary files into it. This way all ASP.NET temporary files get created amazingly fast (in-memory) and greatly speeds up your debugging experience.

Labels: ,


# posted by Martin Kulov @ 2:02 AM

Share |


|




November 18, 2009

PDC 2009 News

Microsoft just announced a bunch of new codenames. It is really hard for me to go into every single one of them so I will provide the highlights as I see them:

Read more about the keynote at PDC09 Virtual Pressroom.

Labels: , , , ,


# posted by Martin Kulov @ 1:56 AM

Share |


|




January 25, 2008

Precompiled sites and VirtualPathProvider

Coskun Sunali posted an amazing article how you can set up VirtualPathProviders to run when using Precompiled sites.

Do you know that even MS do not use VPP in precompiled sites? Check this out.

This is just an example what you can achieve with Reflector and a lot of patience.

(The support for VPP is explicitly disabled in precompiled sites by Microsoft. We do not know the reasons why they did it, so please you this fix with careful testing :).)

Good work Josh!

Labels: ,


# posted by Martin Kulov @ 3:27 AM

Share |


|




January 22, 2008

COMException loading solution

Happy New Year to all of you! I hope that my blog will keep helping you solve problems that are really tough to find.

Recently I bumped into a very strange problem when I tried to open a fresh new solution from the source control and then I got a strange error -  Microsoft Visual Studio - System.Runtime.InteropServices.COMException:

System.Runtime.InteropServices.COMException

I wonder what the Cancel button will do here, but that is a different story.

A quick look at Solution Explorer, showed that all projects were loaded successfully except one - a Web Application Project.

I put some time to dig in with WinDbg and then I got some tips on what is going on.

In order to load the Web Application Project you must make sure that the URL that the project is using, is valid and can be resolved. This can happen pretty often since when you download a project from source control for the first time, it is highly unlikely that you will have the web site already set up.

And important note that I have to make also is that if you are running Vista, you should run in elevated privileges as well.

Using Web Application Projects is not really my choice for web site development. I would rather choose the new Web Site model. I hope that I will have the time to go further into this topic here.

The problem is reported to Microsoft and will be fixed in VS2008 SP1 (no date has been announced yet).

Labels: , ,


# posted by Martin Kulov @ 12:22 AM

Share |


|




December 12, 2007

ASP.NET 3.5 Extensions Preview is Released

The preview version of ASP.NET 3.5 Extensions is released. The Extensions are a new set of tools and controls that will be added onto existing release of ASP.NET with .NET 3.5. This will make possible for web developers to get the latest updates on ASP.NET without having to wait 1-2 years more for the next release of .NET Framework.
It also includes ADO.NET Entity Framework Beta 3, which you can also download as a separate file here (you do not need to download it if you have ASP.NET 3.5 Extensions Preview installed already).


What’s in the Extensions Release?

ASP.NET MVC
ASP.NET MVC provides model-view-controller (MVC) support to the existing ASP.NET 3.5 runtime, which enables developers to more easily take advantage of this design pattern. Benefits include the ability to achieve and maintain a clear separation of concerns, as well as facilitate test driven development (TDD).

The ASP.NET MVC Toolkit provides HTML rendering helpers and dynamic data support for MVC.

ASP.NET Dynamic Data
ASP.NET Dynamic Data helps developers build a fully customizable, data-driven app quickly. It provides a rich scaffolding framework that allows rapid data driven development without writing code, yet it is easily extendible using the traditional ASP.NET programming model.

ASP.NET AJAX
New additions to ASP.NET AJAX include support for managing browser history (Back button support).

ADO.NET Entity Framework
ADO.NET Entity Framework is a new modeling framework that enables developers to define a conceptual model of a database schema that closely aligns to a real world view of the information. Benefits include easier to understand and easier to maintain application code that is shielded from underlying database schema changes.

ADO.NET Data Services
ADO.NET Data Services provide new services that find, manipulate and deliver data over the web using simple URIs. Benefits include an easy and flexible way to access data over the web, while enabling the separation of presentation and data access code.

Silverlight Controls for ASP.NET
You can integrate the rich behavior of Microsoft Silverlight into your Web application by using two new ASP.NET server controls: a MediaPlayer server control that enables easy integration of media sources such as audio (WMA) and video (WMV) into your Web application, and a Silverlight server control that allows an ASP.NET page to reference both XAML objects and their event handlers.

Labels: ,


# posted by Martin Kulov @ 12:41 AM

Share |


|




This page is powered by Blogger. Isn't yours?

 








Recent posts



Locations of visitors to this page



History




 
Copyright © 2004-2008 CodeAttest Ltd. All Rights Reserved.
<%-- Google Analytics code --%> <%-- Google Analytics code --%>