ImageVerifierCode 换一换
格式:DOCX , 页数:12 ,大小:435.27KB ,
资源ID:21818602      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bdocx.com/down/21818602.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(Diagnosing Issues in Production with IntelliTrace and Visual Studio 11Word格式.docx)为本站会员(b****6)主动上传,冰豆网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰豆网(发送邮件至service@bdocx.com或直接QQ联系客服),我们立即给予删除!

Diagnosing Issues in Production with IntelliTrace and Visual Studio 11Word格式.docx

1、Exercise 1: Using IntelliTrace in Production 4Exercise 2: Debugging with IntelliTrace Files from Production 10OverviewIntelliTrace first released in Visual Studio 2010 changed the game for debugging by allowing developers to step “back in time” to see how an application got into its current state. B

2、y exposing events such as file and registry access, exceptions, and method calls, an IntelliTrace file can provide a detailed view into application behavior. In this lab, you will learn how Visual Studio 11 will extend the capabilities of IntelliTrace beyond the development and testing organizations

3、 by providing IT administrators with the ability to capture IntelliTrace files running from production servers. These files can then be analyzed by developers to help diagnose production issues.PrerequisitesIn order to complete this lab you will need the Visual Studio 11 virtual machine provided by

4、Microsoft. For more information on acquiring and using this virtual machine, please see this blog post.About the Fabrikam Fiber ScenarioThis set of hands-on-labs uses a fictional company, Fabrikam Fiber, as a backdrop to the scenarios you are learning about. Fabrikam Fiber provides cable television

5、and related services to the United States. They are growing rapidly and have embraced Windows Azure to scale their customer-facing web site directly to end-users to allow them to self-service tickets and track technicians. They also use an on-premises ASP.NET MVC application for their customer servi

6、ce representatives to administer customer orders.In this set of hands-on labs, you will take part in a number of scenarios that involve the development and testing team at Fabrikam Fiber. The team, which consists of 8-10 people, has decided to use Visual Studio application lifecycle management tools

7、 to manage their source code, run their builds, test their web sites, and plan and track the project. ExercisesThis hands-on lab includes the following exercises:1. Using IntelliTrace in Production2. Debugging with IntelliTrace Files from ProductionEstimated time to complete this lab: 60 minutes. Us

8、ing IntelliTrace in ProductionIn this exercise, you will learn how to deploy and use IntelliTrace in Production to capture trace information for an ASP.NET application.3. Log in as Adam. All user passwords are P2ssw0rd.4. Launch Internet Explorer and click on the FF Customer Portal button in the fav

9、orites bar to load the customer portal for Fabrikam Fiber Support ().Figure 1Fabrikam Fiber customer portal5. Select a few of the service tickets from the My Tickets section of the page to view their details until you come across one that indicates that an error occurred retrieving data from the ser

10、ver. This information is ultimately pulled from a database, but there could be any number of reasons for the general error message itself.Figure 2Error message shown when selecting service ticket6. Close Internet Explorer.7. Typically, the first step in determining the root cause of an error like th

11、is would be to check logs for details and perhaps a stack trace. If that does not provide enough information, and the error is not easily reproduced in a development environment, the development team may end up taking a long time to determine the root cause and fix the problem. Installing Visual Stu

12、dio or other debugging tools in a production environment may not be an option.8. Now lets look at how to deploy and use IntelliTrace in a production environment to collect historical debugging data. Open a Windows Explorer window and navigate to the root of the C: drive. Note that there are two fold

13、ers here that were created ahead of time for our use in this lab, c:IntelliTrace is where the standalone IntelliTrace files are placed and c:LogFileLocation is where the IntelliTrace files will be written to later on in this lab.Figure 3Location of IntelliTrace files folder and log file folder9. In

14、an Explorer window, right-click on the LogFileLocation folder and select Properties to open the Properties window. We need to make sure that the IIS application pool has permission to use the LogFileLocation folder.10. Select the Security tab and then scroll down the existing list of groups and user

15、 names to find FabrikamFiber.Extranet.Web. Permissions were added ahead of time in this VM, but in a production environment, you would need to make sure to perform this step yourself. Figure 4Setting security to enable log files to be written11. Press the Escape key to exit out of the properties win

16、dow.12. IntelliTrace can be deployed to a production environment simply by extracting the contents of the IntelliTraceCollection.cab file that ships with Visual Studio 11. This task has also been performed ahead of time in the VM for your convenience, so there is no need for you to perform this step

17、.Figure 5Extracted contents of IntelliTraceCollection.cab fileNote: For the purposes of this lab, the production system is the same as our development system, but that will not normally be the case.13. Open a PowerShell window and type the following command to import the IntelliTrace PowerShell modu

18、le:Import-Module c:IntelliTraceMicrosoft.VisualStudio.IntelliTrace.PowerShell.dll14. To see the commands provided by IntelliTrace, using the following PowerShell command:Get-Command *IntelliTrace*Figure 6Searching for commands that contain “IntelliTrace” Commands are provided to start and stop an In

19、telliTrace collection, as well as to take checkpoints during collection. 15. To get help for any of the PowerShell IntelliTrace commands, type something like the following:Get-Help Start-IntelliTraceCollectionFigure 7Help screen for the Start-IntelliTraceCollection command The REMARKS section from t

20、he help listing describes how you can get more detailed examples of command usage.16. We are now ready to start IntelliTrace collection. Type the following PowerShell command to start collecting data from the FabrikamFiber.Extranet.Web IIS application pool and store the resulting .iTrace log files i

21、n the folder we previously created.Start-IntelliTraceCollection FabrikamFiber.Extranet.Web c:IntelliTracecollection_plan.ASP.NET.trace.xml c:LogFileLocation In the Visual Studio 11 Developer Preview, you can hand-edit the collection plan file if you want to make changes. A graphical editor is expect

22、ed to be provided in a later release.17. When asked to confirm, type “Y” and then press the Enter key to continue.Figure 8Confirming the request to start a collection18. Launch Internet Explorer and click on the FF Customer Portal button in the favorites bar to load .19. IntelliTrace is now setup to

23、 gather the debugging data specified in the collection plan configuration file. Select the service tickets to reproduce the error that we saw before. As soon as you see the error, close Internet Explorer.Figure 9Reproducing the error20. Return to the PowerShell window and type the following command

24、to get the current collection status.Get-IntelliTraceCollectionStatus -ApplicationPool Figure 10Collection status21. Type the following command to stop gathering IntelliTrace data for the FabrikamFiber.Extranet.Web application pool. Confirm the action when prompted.Stop-IntelliTraceCollection As an

25、alternative to stopping an IntelliTrace collection, it is also possible to get a copy of the current log by using the Checkpoint-IntelliTraceCollection command. This allows you to look at the data you have captured so far while continuing to collect additional data.22. In a real-world scenario, it i

26、s at this point that the IntelliTrace file would be sent to a developer or tester for a more detailed look. Debugging with IntelliTrace Files from ProductionIn this exercise, you will see how we can use the IntelliTrace file that was generated on a production server to aid in debugging the error tha

27、t we saw in the previous exercise.23. Returning to our scenario, lets assume that we have already taken this IntelliTrace file and transferred it to a development machine that has Visual Studio 11 installed. Double-click on the IntelliTrace file to load it in Visual Studio 11.Figure 11Loading the In

28、telliTrace file24. In the IntelliTrace summary window, scroll down to the Exception Data section. Here you can see a grid showing all exceptions that occurred. By default, they are sorted by most recent event time to the oldest.Figure 12Exception Data section of IntelliTrace summary25. Select the la

29、st System.NullReferenceException found in the list, that is the technically the oldest or first one that was thrown, and then select the Start Debugging button to start an IntelliTrace debugging session.Figure 13Start debugging at a specific event26. After the IntelliTrace debugging session starts,

30、you will see that the IntelliTrace pane is automatically loaded and the location in code where the exception occurred is highlighted. You now have full access to the normal suite of IntelliTrace debugging functionality.Figure 14Debugging the thrown exception27. In the Locals window, note that the Se

31、rviceTicket.AssignedTo property currently has a null value. This explains why referencing serviceTicket.AssignedTo.FullName in code resulted in the null reference exception that we saw. At this point, we could file a bug in Team Foundation Server and attach the IntelliTrace file to help the development team make the appropriate fix.Figure 15Finding root cause for exceptionTo gi

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1