Timing

Sometimes it might be interesting to check how long certain action took. You can use our timing debugging for this. To use this, you first need to set the debug mode to “timing”. You can do this with executing the following code in the console.

harvest.setDebug("timing");

After you have done this, reload the page.

You can then check how long certain actions took. We have the following options:

Timing label Description
Event process time This timer times the process time of the last processed event.
Harvest Collect - Initialization Milliseconds for Harvest Collect to initialize.
Harvest Listener - Initialization Milliseconds for Harvest Listener to initialize.
Harvest - Initialization Milliseconds for Harvest Collect and Harvest Listener to initialize.
Harvest Collect - First pageview Milliseconds from start of Harvest until the first pageview to be processed.
Harvest Collect - Queue time Milliseconds it took to process queued events after Harvest Collect was initalized.
DOM Ready time Milliseconds between start of Harvest until DOM Ready.
Initiated pageMetaData time Milliseconds until Harvest Listneer intiated pageMetaData.

To retrieve a specific, you can use the following code:

harvest.timer("Event process time");

In the above example you can change “Event process time” for any other label.

Note: