开发者

ASP.NET measure performance

I have a Page with 5 usercontrols. This page takes long time to load. I am loading this page in Iframe(jQuery Colorbox Plugin). how can I measure loading time for each usercon开发者_运维知识库trol ? And checking which usercontrol or action causes this problem for me.


Your Choice should be Tracing

ASP.NET tracing enables you to view diagnostic information about a single request for an ASP.NET page. ASP.NET tracing enables you to follow a page's execution path, display diagnostic information at run time, and debug your application. ASP.NET tracing can be integrated with system-level tracing to provide multiple levels of tracing output in distributed and multi-tier applications.

ASP.NET Tracing Overview

Tracing in ASP.NET


Use the VS2010 built in profiler. It will show you the code paths that have the highest cost.

Details:

Click Analyze->Launch Performance Wizard... on the VS2010 main menu. (I have VS Ultimate, I am not sure if this is available in all versions.

Select Instrumentation. Click Next. (experiment with all the options! :D)

Choose the project you want to analyze. Click Next.

Select Enable Tier Interaction Profiling if needed. Click Next, then click Finish.

VS will now launch IE and run your app. Perform the actions in your application that you want to inspect. Close IE.

The profiling report will be shown that will give the details of the profiling session. Pay particular attention to the "Hot Path".

Have fun debugging!


dotTrace is my favorite profiler; it's really, really helpful and detailed.

Request tracing may not give you enough information to find the bottle-neck, as the slowness on your page may not be ASP.NET related.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜