Time to Interact

Testing AJAX websites is challenging

Measuring the user experience of AJAX websites with the timings the browser provides can be difficult. A user can consider a web page as ready, although the processing in the background is not yet completed. Also, the processing might be completed, but the web page is not yet ready for the user at that point in time. Essential page elements might be loaded asynchronously, that is after the onLoad Function phase and during the Asynchronous Application Logic phase. In such a case, the perceived loading time of a web page can differ considerably from the measured loading time. As a result, Silk Performer introduced the so-called Time to Interact (TTI).

The Time to Interact

In Silk Performer terminology, the Time to Interact is defined as the time from a user interaction (such as navigating to a URL or a click on a link) until all relevant elements a user requires to interact with the page are ready; even if the page has not yet completely loaded. Identifying the relevant elements of a page can not simply be automated, as it heavily depends on the use case and on the perspective which elements to consider relevant. For example: A web shop company can test their website from their own perspective and from the perspective of their customers. From the company-perspective, the elements that contain the special offers might be considered relevant. But from the customer-perspective, just the search field might be considered relevant.

Therefore, the performance engineer has to tag all TTI-relevant elements during recording. The Recorder then generates a BrowserTtiIncludeElement() function for each of these tagged elements. During replay, Silk Performer measures how long it takes to load each TTI-relevant element and reports the maximum as the Time to Interact.

Browser-driven Measures

For browser-driven tests, Silk Performer provides the following measures:

Measure Description
Dom interactive Reflects the time span from the request until the browser has completed parsing all HTML elements and constructing the DOM.
Dom complete Reflects the time span from the request until the browser has completed downloading and processing all resources (images, stylesheets, scripts, and so on).
Load End Reflects the time span from the request until the browser has completed executing the onLoad function. As a final step in every page load process the browser sends an onLoad event, which triggers the onLoad function. Once the onLoad functions are executed, additional application logic might be executed.
First paint Reflects the time span from the request until the page begins to display. This measure is available for Internet Explorer only.
Time to interact Reflects the time span from the request until all TTI-relevant elements are available on the page. At this point in time, the user can interact with the web page.
Action time Reflects the time span from the request until the browser has completed downloading and processing all resources. The end of this time span varies, depending on the defined synchronization mode: If the synchronization mode HTML is defined, the action time ends when the onLoad function is completed. If the synchronization mode AJAX is defined, the action time ends during the Asynchronous Application Logic phase.
Note: DOM interactive, DOM complete, and Load end can be described as consecutive events. These events all end during the Processing phase. In contrast, First paint and Time to interact are completely website-dependent; they can end in the HTTP Response phase, in the Processing, and in the Asynchronous Application Logic phase.
Important: When the TTI feature is being used, the other measures listed here might not be available or might show incorrect values.