JavaScript Long Task Or Browser Freeze Detection Configuration

✨ Feature

Germain UX RUM JS captures Javascript Long Task that occupies the UI main thread for 3 seconds or more. Usually that blocking and uninterrupted task causes:

Issue

Details

Bad animations and scrolling

Bad animations and scrolling

Browser Freeze

Browser Freeze

Delayed time to interactive (TTI)

Delayed time to interactive (TTI)

High input and event handling latency

High input and event handling latency

By default, this monitoring is enabled for each User Monitoring Profile.

What the Chrome team says about Javascript Long Task: https://web.dev/long-tasks-devtools/.

⚙️ Configuration

📏 Threshold

You can update long task threshold by setting settings.plugins.performance.longtaskThresholdMillis in the Init Script.

The following code sample shows how to collect long tasks only if equal or longer than five seconds.

JavaScript
const settings = germainApm.getDefaultSettings();
...
settings.plugins.performance.longtaskThresholdMillis = 5000; // in milliseconds
...
germainApm.start(settings);


📈 KPIs

KPI Name

Details

KPI Name: “Javascript Long Task - Browser Freeze”.

KPI Name: “Javascript Long Task - Browser Freeze”. More details.

📷 Example

Long Tasks on Drill-through


image-20231219-104330.png


Component: RUM JS

Feature Availability: or later

Browser Support: only latest Chrome, Edge and Opera