views:

14

answers:

1

I've noticed as my website gets bigger and bigger, the time my laptop takes to display my page is much longer then say a new projects with minimal references.

I think there are two variables at play that affect ASP.NET warm-up time:

  • The quantity of external references
  • The time it takes for a worker process to new() up each instance per worker process
  • Additional time for the WCF objects as the ServiceHost may be in an external DLL

First, are those the correct variables to take into account when considering ASP.NET startup time?

Next, it appears that web.config may dispatch other objects for use with certain filetypes (*.svc, *.aspx, Windows Identity Foundation (WIF), etc. ). This too may cause delays in ASP.NET.

Last, my project is created as a "web project" not a "web site". Not sure if this has an impact.

Is my theory full of holes, or is there something I can do to make development on a old laptop any better?

A: 

The worker process will load any references into the AppDomain as they are needed. This means when the application first starts up not all of your referenced assemblies may be loaded. If you are finding a lot of your bootstrapping time (the initial application start up time) is increasing, I would consider looking at exactly what you are doing in your Application_Start method, etc. The other thing to remember, is that this initial startup time is essentially a one off, it will only occur for each application startup (don't forget when your application pool gets recycled too). Because it is a one time thing, does the start up time matter? Once the site has had its initial page view, execution from that point onwards should be quite speedy.

You could run something like ANTS Profiler, or dotTrace and profile exactly where all the time is being spent, and then decide what performance improvements you wish to make based on that information.

Matthew Abbott
@Matthew Abbot The main reason I care a about start up time is because I generate many builds before I release to production... and I work with an offline almost exact copy of my site. Maintaining this large site is becoming time consuming and inefficient
MakerOfThings7
Grab yourself a profiler and see what's going on. It would sounds like your code is potentially doing something time consuming. A profiler should highlight the length processes for you.
Matthew Abbott
Perhaps it's even VS doing a compile that takes long. Can you point me to any Profiling 101 information? Never did that before... especially in this context.
MakerOfThings7
I use JetBrain's dotTrace (http://www.jetbrains.com/profiler/). Essentially, you run the profiler by attaching it to the web server (the profiler application can do this for you). There is an introductory video on their website, and a 30-day trial. You may find it a worthy purchase, I know I did...
Matthew Abbott