Management & Debugging

Cache management and debugging tools that are available out of the box to help you solve problems faster.

XprTrace


XprTrace is available when logged into the XPR Backend as a Site Developer account at {yourdomain}/XprTrace/.

While the XprTrace page is open, requests from the same session (for example, on another tab) will be tracked in XprTrace. Structured data about the request is available by clicking on the Inspect In Console link while your browser's Developer Tools are open.

Boson Profiler


The Boson Profiler profiles the execution of your various code elements in play on a given request. You can run a profile pass on a given URL by passing the query params BosonProfilerRun=1&BosonProfilerFormat=html. Links to run the profiler for each request are displayed on the XprTrace page.

When in html mode, the execution time is shown subdivided in a type of graph called a Treemap. You can drill down into further detail by left clicking, and navigate back up by right clicking.

The BosonProfilerFormat parameter can also be set to json, which emits the raw data used to build the treemap.

XprCacheControl


Expression utilizes a serverside caching engine to reduce time spent generating a response and serve up API objects directly from cache when they haven't changed recently. Typically this caching is invisible to both users and developers, but under extremely rare conditions, an object may appear to get "stuck" in the cache.

The cache can be cleared by navigating to {yourdomain}/XprCacheControl/ and pushing the "Purge All Caches" button.

SSJS Error Log

Serverside Script errors are dequeued to the SSJS error log in the XprBackend.

Activity Log


The Activity Log tracks all non "GET" requests made over HTTP to the XPR API.

Global Debug Flag


The Global Debug flag is configurable from the top right User menu in the Expression backend. The debug state is accessible within Scripts and Elements by way of the XprRequest.debug property in scripts or {{xpr.request.debug}} in Elements.

It is reccomended to use this flag to switch code paths on and off, for example: surpressing a mailer call or including extra data in the render layer to assist with debugging your application.