The Artima Developer Community
Sponsored Link

.NET Buzz Forum
Debugging Tricky Issues with Red-Gate's ANTS Profiler

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Brendan Tompkins

Posts: 158
Nickname: brendant
Registered: Apr, 2005

Brendan Tompkins is .NET Developer and founder of CodeBetter.Com
Debugging Tricky Issues with Red-Gate's ANTS Profiler Posted: Jul 14, 2005 9:20 AM
Reply to this message Reply

This post originated from an RSS feed registered with .NET Buzz by Brendan Tompkins.
Original Post: Debugging Tricky Issues with Red-Gate's ANTS Profiler
Feed Title: Brendan Tompkins
Feed URL: /error.htm?aspxerrorpath=/blogs/brendan.tompkins/Rss.aspx
Feed Description: Blog First. Ask Questions Later.
Latest .NET Buzz Posts
Latest .NET Buzz Posts by Brendan Tompkins
Latest Posts From Brendan Tompkins

Advertisement

I ran into a head-scratcher of a problem recently with WSMQ's new DbProvider, using the June Enterprise Library Data Access Application Block.

I noticed that when running WSMQ under a low trust account, the application is initially very slow to respond.  Eventually, things seem to return to normal, but whenever the aspnet worker process is restarted, the application is again sluggish for a time period.  I couldn’t figure out what was causing this slowness.  It wasn’t my SQL server connection, it wasn’t simple assembly caching. Something was timing out, then getting cached, but what?

Enter Red-Gate’s ANTS Profiler

Like all their tools, I highly, highly recommend ANTS Profiler. Raymond has a great review of ANTS here.  Their SQL and ANTS tools  should be an essential component of any .NET developers suite of tools. Oh, and there’s a period at the end of that sentence.

ANTS Profiler™ is the simple .NET profiler that pinpoints slow lines of code in .NET applications and helps you understand how your application is using memory.

Anyhow, when I fired up ANTS, I  noticed that when I run WSMQ under a low-trust account, a call to the WMI’s IWebmLocator.ConnectServer is being made, and it's taking up 45 seconds during a simple profiling session!

So, I started looking into code and found that even though I only had the Data Access Application Block configured, it was in fact, making WMI instrumentation calls.  This will require running under a high-trust account, something that I couldn’t require with an app that is designed to be deployed anywhere, even on a trusty WebHost4Life account.

I found this post that showed me how to turn this stuff off, EntLib Required Post-Installation Step.

I don't recommend it, but if you really want to you can also disable all of the WMI and performance counter instrumentation in Enterprise Library. This requires a recompile of Enterprise Library, and you will lose valuable performance monitoring data.

Well, I do really want to do it, so here was my solution: Open the the EnterpriseLibrary.sln and modify the Configuration Properties\Build\Conditional Constants of the EnterpriseLibrary.Common project.  I had to remove the conditional build constants that were mentioned in @baz’ post.

The point of this post?  I would have never even known where to look without ANTS!   This is really a great tool.  Thanks Red-Gate!

-Brendan

Read: Debugging Tricky Issues with Red-Gate's ANTS Profiler

Topic: Google's Ranking Previous Topic   Next Topic Topic: Visual Studio 2005 Visualizers

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use