Expand my Community achievements bar.

Join us for the next Community Q&A Coffee Break on Tuesday April 23, 2024 with Eric Matisoff, Principal Evangelist, Analytics & Data Science, who will join us to discuss all the big news and announcements from Summit 2024!
SOLVED

List variable for performanceTiming plug-in

Avatar

Level 6

I'm trying to understand how to implement the performanceTiming plug-in and it says a list variable is needed:

"If you wish to utilize the asset load time functionality within the plug-in, you must pass in the name of the list variable to be used."

What is the use case for using a list variable with the performanceTiming? If I don't use a list variable, then what information will I get?

1 Accepted Solution

Avatar

Correct answer by
Level 3

If you use a List Variable, you'll get the timing measurements for the individual assets that make up the page (e.g., individual JavaScript libraries) - this will be a lot of data.

If you just configure the ten (10) events in s.pte, you'll get nine (9) calculated timings for the performance of the page as a whole, from the point that the user clicks a link to load the page up to the point that the page finishes loading; the tenth event is a counter to help with creating calculated metrics.

View solution in original post

6 Replies

Avatar

Correct answer by
Level 3

If you use a List Variable, you'll get the timing measurements for the individual assets that make up the page (e.g., individual JavaScript libraries) - this will be a lot of data.

If you just configure the ten (10) events in s.pte, you'll get nine (9) calculated timings for the performance of the page as a whole, from the point that the user clicks a link to load the page up to the point that the page finishes loading; the tenth event is a counter to help with creating calculated metrics.

Avatar

Level 6

Will the 10 events be in the events list on a the next page load?

Avatar

Level 3

That's right:  the measurements are collected on the next page load, which is why the article instructs the setting of a "Performance Timing Page Name" variable as well (the measurements will be analysed against this variable, and ​not​ the Page Name).

Do you customise s.linkTrackVars for Exit and / or Download links?

Note that the measurements are also captured on Exit Link clicks, so the "Performance Timing Page Name" variable needs to be included in s.linkTrackVars if you're customising it for link-tracking calls.

Avatar

Level 6

Thanks for confirming. I'm asking because I don't see the events showing up on the next page load.

Avatar

Level 6

Based on the example:

/* Performance Timing */

s.eVar9 = s.getPreviousValue(s.pageName,'gpv_v9',''); //Record the previous page name in the designated eVar of your choice

s.performanceTiming('list2')

If we don't use a list, should the call be:

s.performanceTiming('eVar9')

instead of

s.performanceTiming('list2')

?

Avatar

Level 3

Actually, if you're only interested in the page load times (and not the asset timings), the call should just be:

s.performanceTiming()

You should be able to read the contents of the cookie (where the timings are stored for reading on the next page) by inspecting it in the Console before navigating:

s.Util.cookieRead('s_ptc');

Should look something like this:

"0.00^^0.00^^0.00^^0.00^^0.09^^0.00^^6.25^^0.01^^6.36"

If that cookie's not being set, you've possibly got a timing problem (we had this on our site and had to modify the plug-in and the code we added to s_doPlugins).