Integration Debugging with PerformancePoint Server 2007 CriTrace

Eric Friedrichsen (ericfr@microsoft.com)

Microsoft Corporation

November 2007

Required:
Microsoft Office PerformancePoint Server 2007 Dashboards

Summary: While you're developing software that integrates with PerformancePoint Server 2007 Dashboards, you may find it helpful to turn on CriTrace. CriTrace traces all the calls to the CreateRenderingInstructions web method in RenderingService.asmx and dumps the parameters passed to that web method out to the server's file system as xml files.

Introduction

The CreateRenderingInstructions web method in RenderingService.asmx is called every time a web browser needs to render a PerformancePoint Server 2007 Dashboard Item. This is true whether the Dashboard was created as a SharePoint page or as an ASP.NET web page. This is true regardless of whether the Dashboard Item is a Scorecard, Report View, Filter Web Control, your own Custom Report View, or your own Custom Filter Web Control.

Using PerformancePoint Server CriTrace is interesting if:

· You are integrating with the PerformancePoint Server 2007 Dashboards thin client, and you just want a quick way to convince yourself that the browser call to the server is actually reaching RenderingService.asmx.

· For testing purposes, you wish you could 'record a macro' of the web browser user's filter selections.

· You are integrating with PerformancePoint Server 2007 Dashboards, and are debugging your Custom Report View Plug-in (see my blog here), and want to examine the html generated by your Report View before the html is escaped and returned by the CreateRenderingInstructions web method.

· You are integrating with PerformancePoint Server 2007 Dashboards, and are debugging your Custom Report View Plug-in (see my blog here), and want to see precisely what filter information is being passed to your Custom Report View.

· You are integrating with PerformancePoint Server 2007 Dashboards, and are developing a Custom Filter Web Control, and want to see precisely what filter information is being passed from your Custom Filter Web Control.

· You are building an automated process that generates an Excel or PowerPoint Report Deck based on PPS 2007 M&A Dashboards, and you want to take a snapshot of the filter information passed from one Dashboard Item to another. You want to use that filter information snapshot as a way of filtering your generated Excel or PowerPoint Report Deck. (Used in this way, the filter information snapshot is like recording a macro of the web browser user's filter selections.)

Applies To

This article applies to the following cases:

· You've already installed Microsoft Office PerformancePoint Server 2007 on some server, and created Dashboards containing Scorecards and ReportViews on that server. You also have access to that server and have permissions to view the PPS 2007 Dashboards on that server.

Turning on CriTrace friendlyfile

In order to turn on "friendlyfile" feature you have to add the following highlighted setting to the web.config of the RenderingService.asmx:

  <appSettings>

    <add key="CriTrace" value="friendlyfile" />

    ...

  </appSettings>

This causes an xml representation of the parameters passed to the CreateRenderingInstructions web method (in RenderingService.asmx) to be dumped to current temp directory:

critrace

You can find the calls to CreateRenderingInstructions for a particular dashboard by searching on "CriTrace.dashboardName.*.xml".

You can find the calls to CreateRenderingInstructions for a particular dashboard item by searching on "CriTrace.dashboardName.dashboardItemName.xml".

As each call to CreateRenderingInstructions is made, the xml file for the given dashboard item is overwritten.

(Note: This causes a problem if you have dashboards of the same name. In that case, you should use <add key="CriTrace" value="file" /> instead of <add key="CriTrace" value="friendlyfile" />. Using "file" will cause the dumped xml file names to be based on dashboardId.dashboardItemId instead, which is in the form GUID.GUID.)

The output of each file looks something like this:

<renderingInstruction>

<parameters>

<dashboardId><![CDATA[b3a499a7fec3459696a455423dcfca80]]></dashboardId>

<resourcePath><![CDATA[https://ericfr-003/_wpresources/Microsoft.PerformancePoint.Scorecards.WebParts/3.0.0.0__31bf3856ad364e35/]]></resourcePath>

<targetControlId><![CDATA[ctl00_m_g_e352a201_195d_486a_befb_82f053f80aa4]]></targetControlId>

<targetControlType>

<![CDATA[Microsoft.PerformancePoint.Scorecards.WebControls.ScorecardCtrl, Microsoft.PerformancePoint.Scorecards.WebControls, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]>

</targetControlType>

<proxyId><![CDATA[DashboardItem_329aaa41143745dd894f0d16e7e4dcd8]]></proxyId>

<availableHeight><![CDATA[214px]]></availableHeight>

<availableWidth><![CDATA[421px]]></availableWidth>

<dashboardItemId><![CDATA[329aaa41-1437-45dd-894f-0d16e7e4dcd8]]></dashboardItemId>

<inboundSerialStamp><![CDATA[4]]></inboundSerialStamp>

<inboundParameters>

<!--the inboundParameters of the control-->

</inboundParameters>

<beginPoints>

<!--the beginPoints of the control-->

</beginPoints>

</parameters>

<html>

<!--the html of the control, before the addition of spy settings, before the application of pre-transmission escapes-->

</html>

<customRenderScript><![CDATA[]]></customRenderScript>

<error><![CDATA[]]></error>

</renderingInstruction>

If you are interested in the filters passed to the DashboardItem, examine the contents of the <inboundParameters> element.

Don't forget to turn CriTrace OFF

When you are done debugging, don't forget to turn CriTrace off by removing the <add key="CriTrace" value="friendlyfile" /> from the web.config file of the RenderingService.asmx. CriTrace slows performance down and should only be turned on while debugging.

Conclusion

You can use the above approach to turn on CriTrace. CriTrace traces all the calls to the CreateRenderingInstructions web method in RenderingService.asmx and dumps the parameters passed to that web method out to the server's file system as xml files.