[TP] Lab - Visualize and analyze your user experience (DEM)


In this lab, we will put into practice USQL queries and Funnel creation to analyze user experience.

What you will learn in this TP :
  • Access the Dynatrace SaaS environment
  • Prepare your workspace for the lab
  • Differentiate application types (Experience Vitals, Web, Mobile, Frontend)
  • Access an application for our analysis
  • Understand the application's Apdex score
  • Compare the current week's Apdex with last week's
  • Find the application's Core Web Vitals
  • Identify and display the services contributing to the application's functioning
  • Access the application's Smartscape view
  • Differentiate 1st party, CDN and 3rd party resources
  • Specifically display 3rd party resources
  • Display the distribution between new users and returning (old) users
  • Display user types (Real users, Synthetic, Robots)
  • Access user sessions
  • Verify GDPR activation
  • Analyze a session's details
  • Visualize a session replay
  • Access the User sessions query interface
  • Understand basic USQL syntax
  • Filter user sessions with errors
  • Use aggregation functions like GROUP BY
  • Understand the concept of a funnel
  • Build a multi-step USQL query
  • Analyze a user conversion journey

Prerequisites and connection


What you will learn in this section :
  • Access the Dynatrace SaaS environment
  • Prepare your workspace for the lab

For this lab, we will use the dedicated SaaS platform. You must connect to the following address: https://wkf10640.apps.dynatrace.com/.
Please contact your trainer to obtain the connection credentials.

Discovery of applications


What you will learn in this section :
  • Differentiate application types (Experience Vitals, Web, Mobile, Frontend)
  • Access an application for our analysis

Before analyzing the data, it is important to understand the different types of applications managed by Dynatrace and know how to access them.
  1. Application types
    In Dynatrace, applications are categorized to better adapt data collection. What is the difference between a Web, Mobile and Frontend application?
  2. Access to the EasyTrade application
    For the rest of this lab, we will work on the 'EasyTrade' web application and analyze it in the 'Frontend' Dynatrace application. Find and access this application from the main menu.

Performance analysis


What you will learn in this section :
  • Understand the application's Apdex score
  • Compare the current week's Apdex with last week's
  • Find the application's Core Web Vitals

Apdex (Application Performance Index) and Core Web Vitals are metrics for measuring user satisfaction regarding application performance and response times.
  1. Apdex comparison
    Display the comparison between this week's Apdex and last week's. This is very useful in a company, for example, to verify performance gains or losses following a recent deployment to production (MEP).
  2. Core Web Vitals
    In this section, use the Experience Vitals application to quickly find our application's core web vitals.

    If you want details on the difference between apdex vs core web vitals you should read this article : Apdex vs Core Web Vitals.

Underlying services analysis


What you will learn in this section :
  • Identify and display the services contributing to the application's functioning
  • Access the application's Smartscape view

A Frontend application generally relies on several Frontend and Backend services (APIs, databases, etc.). If an application is slow, it may come from one of these services.
  1. Display connected services
    Find how to display the list of services that are called by the EasyTrade application.
  2. Smartscape view (Smartscape topology)
    Find how to access the Smartscape view (Smartscape topology) specific to the EasyTrade application to visualize its end-to-end dependencies.

Resources analysis


What you will learn in this section :
  • Differentiate 1st party, CDN and 3rd party resources
  • Specifically display 3rd party resources

During page load, multiple resources (images, scripts, CSS) are downloaded. It is crucial to categorize them to identify the source of slowness (which can sometimes be external).
  1. Resources categorization
    Dynatrace automatically classifies your application's resources. Familiarize yourself with the different categories.
  2. Display 3rd party resources
    Display the list of '3rd party resources' for the EasyTrade application.

User behavior


What you will learn in this section :
  • Display the distribution between new users and returning (old) users
  • Display user types (Real users, Synthetic, Robots)

Behavior analysis helps to understand whether your application is attracting new users or retaining existing ones.
  1. New vs Returning users
    Find how to display the distribution between the number of new users (New users) and known/returning users (Returning users).
    User Types Screenshot
  2. User types
    Find how to display the distribution of user types visiting your application.

    Difference between user types:
    • Real users : These are the real human visitors interacting with your application via their browser or mobile device.
    • Synthetic : These are the executions of your own synthetic monitors (Dynatrace robots) configured to test your application's availability and performance.
    • Robots : These are web bots, crawlers, and spiders (e.g., Googlebot, Bingbot) automatically detected by Dynatrace.


    User Types Screenshot

User sessions


What you will learn in this section :
  • Access user sessions
  • Verify GDPR activation
  • Analyze a session's details
  • Visualize a session replay

Detailed analysis of individual sessions.

GDPR Risk: The collection of session data may include personally identifiable information (PII). It is crucial to ensure user consent is obtained and sensitive data is masked to be fully compliant with GDPR.
  1. Access user sessions
    Find how to list all user sessions for the application.
  2. GDPR status
    Check if the privacy compliance option (Data privacy / GDPR) is properly enabled for this application.

    Collection configuration: To configure this, go to the application settings (Settings) > Data privacy. You can enable 'Opt-in mode' there (which requires explicit consent via a cookie) and configure the masking of IP addresses, keystrokes, and session data (Masking).

    Check out this article for more details: GDPR Management in Dynatrace.
  3. Session details
    Open a specific user session and browse the available details.
  4. Session replay
    Find how to launch 'Session Replay' (if available) to see the user's screen as if it were a video.

    Session Replay Generation: Dynatrace does not capture a standard video stream (which would be heavy and pose strong security issues). Instead, it records DOM (HTML/CSS) mutations and events (mouse, scroll) on the browser side, which it then reconstructs as a 'movie'. Password input fields are automatically masked.

USQL queries


What you will learn in this section :
  • Access the User sessions query interface
  • Understand basic USQL syntax
  • Filter user sessions with errors
  • Use aggregation functions like GROUP BY

Dynatrace DEM applications display information in a fixed structure. To allow you to organize them as you wish in a dashboard, Dynatrace provides the User Session Query Language (USQL) to query user session data.

USQL (User Session Query Language) is Dynatrace's query language for analyzing DEM data. Its syntax is very similar to the standard SQL SELECT statement.

The 4 USQL tables:
  • usersession : Contains global information about the session (e.g., operating system, duration, location).
  • useraction : Contains data on each user action (e.g., page load, click).
  • userevent : Contains custom events triggered during the session.
  • usererror : Groups all errors (JavaScript, network requests) encountered by the user.
  1. Access User sessions query
    Find how to access the user session query interface (User sessions query).
  2. Basic query
    Write a USQL query to list all user sessions that encountered at least one error (JavaScript error, network error, etc.).
    Tip: The interface offers a very useful auto-completion feature. Feel free to use it to easily build your USQL queries without having to memorize the entire syntax.
  3. Browser analysis
    Write a USQL query to count the number of sessions grouped by browser family (browserFamily) to identify the most used browsers.

    Display modes: Once the query is executed, you can modify how the results are presented using the display options (note that some display modes require specific data formatting):
    • Table only: Standard data table display.
    • Bar chart: Bar chart representation, ideal for comparing volumes between different categories (as here, the number of sessions per browser).
    • Pie chart: Pie chart representation, perfect for visualizing each category's proportion relative to the total.
    • Line chart: Time curve representation (requires including a time dimension in the query).
    • Single value: Displays a single value (useful for queries returning a single result like a global COUNT).
    • Funnel: Funnel representation to visualize drop-offs at each step of a journey.
  4. Add to classic dashboard
    Find how to add the result of your USQL query to a classic dashboard (Dashboard classic) so you can quickly view it later without having to re-type the query.

Building a Funnel


What you will learn in this section :
  • Understand the concept of a funnel
  • Build a multi-step USQL query
  • Analyze a user conversion journey

Funnels allow identifying at which step users abandon a given journey. For this exercise, we will use the 'HipsterShopLogs' application.
  1. Page loads identification
    Create a USQL query to list the loaded pages ('Load' type actions) for the 'HipsterShopLogs' application, grouping them by name and counting the number of occurrences.

    Information: This query is not mandatory to create a funnel. However, when you are not very familiar with an application, it proves very useful to identify relevant pages and actions to include in the different steps of your funnel.
    User Types Screenshot
  2. Conversion funnel creation
    Create a USQL query generating a 4-step funnel simulating a classic journey, for example: Homepage -> Product list -> View cart -> Checkout.

Difficulty level: (3/5)

Recommended Articles

License consumption types

Understand the evolution of billing in Dynatrace: the difference between the ...

Grafana Alloy: The importance of Self-Monitoring

Discover why and how to configure Grafana Alloy so that it monitors itself, c...

Grafana Alloy: Understanding and exploiting the User Interface (UI)

Discover how to enable, secure, and use Grafana Alloy's built-in web interfac...

Grafana Alloy: Introduction and Architecture

Discover the fundamental concepts of Grafana Alloy, the transition from the s...

Grafana Alloy: Syntax and Configuration (Alloy Language: River)

As part of a Grafana training or observability training, master the declarati...

Grafana Alloy: Metrics Collection (Prometheus & Ecosystem)

Learn how to configure Grafana Alloy to collect, transform, and forward metri...

Grafana Alloy: Log Management with Loki

Discover how to configure Grafana Alloy to read log files, journald, or netwo...

Grafana Alloy: Trace Management with Tempo

Dive into distributed trace processing. Learn how to ingest OTLP, Jaeger, or ...

Grafana Alloy: Continuous Profiling with Pyroscope

Discover how to configure continuous profiling in your environments using Gra...

Grafana Alloy: Advanced Deployment and Clustering

Learn how to manage large-scale Grafana Alloy deployments. Configure Clusteri...

Grafana Assistant: AI at the service of observability

Discover Grafana Assistant, the artificial intelligence integrated into Grafa...

Grafana Alloy vs Dynatrace ActiveGate: Which to choose?

Comparison between Grafana Alloy and Dynatrace ActiveGate. Understand the fun...

Course Glossary

AIOps (Artificial Intelligence for IT Operations)

The use of artificial intelligence and machine learning to automate and improve IT operations (e.g., anomaly detection, reducing alert noise).

OpenTelemetry

An open source framework providing standards, APIs, and SDKs to collect and export observability data (traces, metrics, logs) in an agnostic way.