Profiling XSLT Stylesheets

 

The XSLT Profiler is available only in Stylus Studio XML Professional Edition.

In addition to debugging tools for XSLT, Stylus Studio provides the XSLT Profiler, a tool that helps you evaluate the efficiency of your XSLT. By default, the performance metrics gathered by the XSLT Profiler are displayed in a preformatted report, like the one shown Figure 239:

Figure 239. XSLT Profiler Report

The report format is controlled by the default XSLT stylesheet, profile.xsl, in the \Stylus Studio\bin directory. You can customize this stylesheet as required. You can save XSLT Profiler reports as HTML.

Note

 

XSLT and XQuery Profiler reports use the same XSLT stylesheet.

In addition to generating the standard XSLT Profiler report, you can save the raw data generated by the Profiler and use this data to create your own reports. See Enabling the Profiler for more information about this procedure.

About metrics

The XSLT Profiler can record three different levels of performance metrics:

  • A call tree of execution times
  • Execution times by XSLT element, and
  • A detailed log of step-by-step element execution

Note

 

Displaying the report for a step-by-step log can take significantly longer than evaluating the XSLT itself. Consider using the Profiler with the first two performance metric options. You can also use the Limit Trace To fields to further restrict the Profiler's scope. If you find you need still more detail (while troubleshooting a performance bottleneck, for example), use the step-by-step setting.

Enabling the Profiler

The XQuery Profiler is off by default. You enable the Profiler on the Profiling Options tab of the XSLT Scenario Properties dialog box.

To enable the XSLT Profiler:
1. Open the Scenario Properties dialog box for the XSLT stylesheet. (Click Browse at the top of the XSLT editor window.)
2. Click the Profiling Options tab.

Figure 240. Profiling Options
3. Select the settings for the performance metrics you want the Profiler to capture.
4. Optionally, save the raw Profiler data to a separate file.

Note

 

This option is available only after you select one or more performance metrics settings.

5. Click OK.

The next time you preview the XSLT results, the performance metrics you selected are available to you in the XSLT Profiler report (and as raw data if you selected that setting and specified a file).

Displaying the XSLT Profiler Report

To display the XSLT Profiler report:
1. Ensure that the Profiler is enabled. (See Enabling the Profiler if you need help with this step.)
2. Click the Preview Result button ( ).
3. Click the Show Profiling Report button ( ).

The XSLT Profiler report appears in the Preview window.

XML Schema Mapping

Stylus Studio includes a visual XML Schema-to-XML Schema mapping tool that allows you to easily implement sophisticated XML data mappings involving multiple data sources and customized data processing using either XSLT or XQuery code.

Web Service Data Mapping

Stylus Studio makes it possible for you to use Web services as live XML data sources for XML mapping projects.

An Introduction To XML Schema Development

An Introduction to XML schema development in Stylus Studio covers some of the highlights of our XML Schema Editor, powerful tools for editing, validating, converting and generating XML schema. Watch the video online today!

Export HTML to XML

Export HTML to XML with the click of a button - simplify migration of legacy HTML code to industry standard XML technologies with Stylus Studio.

Stylus Most Wanted

 
Free Stylus Studio XML Training:
W3C Member