MicroStrategy ONE

Debugging Using Transform Parameters

All Transforms that extend AbstractAppTransform support the debugFlags and debugErrorFlags parameters.

  • The value set in debugFlags for a given transform is applied any time that transform is used to render a Web Bean. The default value is no debug information.  

  • The value set in debugErrorFlags for a given transform is applied any time that transform is used to render a Web Bean and an error is thrown. The default value is all debug information.

These parameters specify to the transform that certain debugging information should be included in the transform’s HTML output. Some of the information that can be included is:

  • Bean Maximal state  

  • Bean XML  

  • Supplied Parameter Values  

  • Request Keys  

  • Browser Settings

These values are defined in the EnumWebAppDebugFlags enumeration, discussed in Debugging Using URL Parameters.

At the end of the transform() method in AbstractAppTransform, the renderDebugInformation() method is invoked. This method checks which flags are set in the debugFlags parameter, and if any, includes the information in the MarkupOutput as an HTML comment.

<!—Debug Info:

<debug>

 <bean name="rb" status="2" output-mode="2">

  <max-state>rb:abc;n:report;mid:12313143213414</max-state>

  <xml>

   <rb><mid>13412341234</mid></rb>

  </xml>

 </bean>

 <transform>

  <parameters>

   <parameter name="cssFile" value="folder.css" />

   <parameter name="cssPrefix" value="folder-" />

  </parameters>

 </transform>

 <application>

  <request keys class="com.microstrategy.web.app.HttpRequestKeys">>

   <key name="abc" value="def" />

   <key name="xxx" value="null" />

  </request keys>

  <browser-settings class="com.microstrategy.web.app.HttpBrowserSettings">

   <key name="abc" value="def" />

   <key name="xxx" value="null" />

  </browser-settings >

 </application>

</debug>

-->

Since the amount of debug information available can get quite large, it is formatted as an XML string so it can be hierarchically browsed with an XML viewer, such as a Web browser.

If an error is encountered in the process of request execution, AbstractAppTransform’s displayError() method is invoked. This method automatically sets the debugFlags parameter value to also include the flags in the debugErrorFlags parameter.