Find Debug Assemblies using Glimpse
Date Published: 03 November 2014
A new feature inGlimpse.AspNet1.9.2 will display whether each assembly in your web site’s bin folder was compiled in Debug or Release mode. At development time, Debug mode is fine, but you want to avoid shipping Debug assemblies to production since there are performance costs associated with these assemblies. You candetermine for yourself whether a given assembly was compiled in debug mode using this code, which also links to the performance issues.
Under the Environment tab in Glimpse, you can scroll down to view the Application Assemblies section. The new column, Build Mode, shows for each assembly how it was compiled. In your production deployments, you want to make sure (for aforementioned performance reasons) that all of the assemblies are built in Release mode.
Thanks to Lohith for implementing this based on a conversation we had back in July!
One more thing I would probably add (and maybe I’ll create a PR for this) is to modify the style of the Release / Debug labels in the Build Mode column. Maybe make Debug bold and red, for instance, so it’s a bit more visible.
Check it out with your application – you may be surprised to find that you’re deploying Debug assemblies to production. Hope this helps!
Steve is an experienced software architect and trainer, focusing currently on ASP.NET Core and Domain-Driven Design.