简体   繁体   中英

Possible to add “offline profiling” functionality to my application?

Being a long time user of Red Gate's ANTS Performance Profiler , I'm currently searching for a way to do profiling on non-development machines.

We have a rather large user base of a WinForms application, written in .NET 4.

Users every now and then complain about poor performance.

Since I cannot buy and install ANTS on every customer's PC, I'm thinking about something like:

  1. Add some magic code to my application that uses the .NET Profiling API .
  2. Provide a switch in my application to enable profiling tracing.
  3. Tell the user to activate the switch.
  4. Let the API record performance "events" for some time.
  5. Tell the customer to ship me the recorded logs.
  6. Open the logs in some fancy GUI to analyse the hotspots.

My question:

Is it somehow possible to use the .NET profiling API to include offline performance hotspot recording to analyse later on?

Update 1:

I've just found the " dotTrace Perfomance API " which introduces the term self-profiling which seems to be just what I'm looking form.

Checking the article now…

Yes, dotTrace API seems to be the best solution. Actually, you can use the same approach as JetBrains uses for ReSharper. There is the option in the ReSharper's Help menu - Profile Visual Studio . What this menu does is run self-profiling. When a user faces a slowdown, JB support asks him to use this menu and reproduce the issue. The collected performance snapshot is then sent to JetBrains.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM