Scott Hanselman

More on WebFarms and WebGardening in ASP.NET

August 24, 2004 Comment on this post [1] Posted in ASP.NET
Sponsored By

Had a short conversation over email and John Lam had this to offer around Web Gardens.  I checked with Corillian's scalability labs and heard that we have found similar results (we recently more than doubled our previous scalability numbers.)

Web gardens look interesting at first, but I spent a lot of time talking with folks at MS about web gardens and the consensus is that web gardens are only useful on very large SMP boxes – 16-way and up. The reason why is that IIS’s sweet spot is on 4-8 proc boxes. By using web gardens on large (>16 proc) SMP boxes and affinitizing CPU’s, you can make IIS think it’s running on a 4-8 proc box when in fact it’s running on a much larger box.

Fantastic information for anyone who's been disappointed with 16 proc IIS performance or for the two-proc folks who are thinking of adding horsepower.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook bluesky subscribe
About   Newsletter
Hosting By
Hosted on Linux using .NET in an Azure App Service

How to turn off/disable the .NET JIT Debugging Dialog

August 24, 2004 Comment on this post [1] Posted in Bugs | Tools
Sponsored By

A day may come when you want to turn off the Debug dialog that appears when a .NET program has an unhandled exception.

Option 1: Registry key from Enabling JIT Debugging

For an application that includes managed code, the common language runtime will present a similar dialog to JIT-attach a debugger. The registry key that controls this option is called HKEY_LOCAL_MACHINE\Software\Microsoft\.NETFramework\DbgJITDebugLaunchSetting.

  • If value = 0, prompt the user by means of a message box. The choices are:
    • Continue. This results in a stack dump and process termination.
    • Attach a debugger. In this case, the runtime spawns the debugger listed in the DbgManagedDebugger registry key. If none, control is returned, and the process is terminated.
  • If value = 1, simply return control. This results in a stack dump, after which the process is terminated.  (No more dialog)
  • If value = 2, spawn the debugger listed in the DbgManagedDebugger registry key.

Option 2: If you want to disable the JIT debug dialog, but still want an error dialog:

Visual Studio.NET|Tools|Options|Debugging|Just-In-Time and deselect "Common Language Runtime" and now you’ll get an OK/Cancel dialog instead of the select a Debugger Dialog.  Note: The registry entry from Option 1 above will need to be 0 for the dialog to show up.

Thanks to Eric Deslauriers of Corillian QA for these tips!

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook bluesky subscribe
About   Newsletter
Hosting By
Hosted on Linux using .NET in an Azure App Service

.NET Compact Framework Examples and Good Demos for Presentations

August 23, 2004 Comment on this post [0] Posted in Programming
Sponsored By

Here's a nice list of .NET CF (Compact Framework) projects you can play with.  The first three items (FotoVision, TaskVision and Signature) make good demos.  These are all courtesy of Vertigo Software.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook bluesky subscribe
About   Newsletter
Hosting By
Hosted on Linux using .NET in an Azure App Service

ASP.NET "Deadlock detected"

August 23, 2004 Comment on this post [0] Posted in ASP.NET
Sponsored By

On a private mailing list Richard Hundhausen dug up this good info if you've ever experienced the "Deadlock detected" error in ASP.NET, perhaps when calling a long running Web Service:

  • KB 821268 http://support.microsoft.com/default.aspx?scid=kb;en-us;821268
  • KB 828222 http://support.microsoft.com/?ID=828222
  • This reply from David Wang (MSFT) on the Google groups with some interesting information:

    You need to turn pinging back on. Report unhealthy depends on failing the ping (and failing the ping is what triggers IIS to recycle the worker process). Enabling pinging should not affect your other recycling options, since all you needed to do was turn off all the time-based recycling metrics -- from a default installation, all you need to turn off are "Idle Timeout" (15 minutes by default) and "Periodic Recycling" (29 hours by default).

    Regarding - responseRestartDeadlockInterval and responseDeadlockInterval -- there isn't anything comparable in IIS6 because ASP.Net is using the "report unhealthy" mechanism to get IIS6 to recycle itself. How the interval is configured should be specific to ASP.Net.

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook bluesky subscribe
About   Newsletter
Hosting By
Hosted on Linux using .NET in an Azure App Service

ASP.NET Interview Questions

August 18, 2004 Comment on this post [45] Posted in ASP.NET | Bugs | HttpHandler | Javascript | ViewState
Sponsored By
If you enjoyed this post, or this blog, please make a secure tax-deductable donation to the American Diabetes Association. Please read my personal story about life as a diabetic and donate today.

I do a LOT of interviewing here, and for a while we were hiring ASP.NET people.  Here's some of the questions that I asked them.  I came up with these questions because you'd "just know" this stuff if you spent time working on a REAL WORLD ASP.NET site - through design, development, debugging, production debugging, and deployment.

Do they suck? Did I miss any?  How do you think people did?

  • From constructor to destructor (taking into consideration Dispose() and the concept of non-deterministic finalization), what the are events fired as part of the ASP.NET System.Web.UI.Page lifecycle. Why are they important? What interesting things can you do at each?
  • What are ASHX files?  What are HttpHandlers?  Where can they be configured?
  • What is needed to configure a new extension for use in ASP.NET? For example, what if I wanted my system to serve ASPX files with a *.jsp extension?
  • What events fire when binding data to a data grid? What are they good for?
  • Explain how PostBacks work, on both the client-side and server-side. How do I chain my own JavaScript into the client side without losing PostBack functionality?
  • How does ViewState work and why is it either useful or evil?
  • What is the OO relationship between an ASPX page and its CS/VB code behind file in ASP.NET 1.1? in 2.0?
  • What happens from the point an HTTP request is received on a TCP/IP port up until the Page fires the On_Load event?
  • How does IIS communicate at runtime with ASP.NET?  Where is ASP.NET at runtime in IIS5? IIS6?
  • What is an assembly binding redirect? Where are the places an administrator or developer can affect how assembly binding policy is applied?
  • Compare and contrast LoadLibrary(), CoCreateInstance(), CreateObject() and Assembly.Load().

About Scott

Scott Hanselman is a former professor, former Chief Architect in finance, now speaker, consultant, father, diabetic, and Microsoft employee. He is a failed stand-up comic, a cornrower, and a book author.

facebook bluesky subscribe
About   Newsletter
Hosting By
Hosted on Linux using .NET in an Azure App Service

Disclaimer: The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.