This Repo contains the labs we are going to work though as part of the BizOps – Bridging the Gap to the Business Hands On Workshop.

For the purposes of the Hands-On, we will automate and make the steps seamless for the participants

Prerequisites

Lab Setup

The following steps are used for this lab:

What You'll Learn

In this lab, we will be doing basic setup within Dynatrace.

Some of these tuning tips has already been done for you.

Marking Key User Actions

Conversion Goal

Conversion Goal

Repeat the above to add the following as key user actions:

In this lab, we will create the following dashboard:

Basic Dashboard

Dashboard Components

The above dashboard has the following components:

Out of the Box Tiles:

Custom Chart Tiles:

In this lab, we will create conversion goals for the easyTravel application

Conversion Goal

Access the easyTravel Website application monitoring settings Applications > easyTravel Website > (...) > Edit

Select Conversion Goals and click Add goal and enter the following:

Conversion Goal

Check results aginst the application: easyTravel > User behavior

Conversion Goal

In this lab, we will create a session properties to expose business data to Dynatrace

Membership Status

1) Access the easyTravel Website application monitoring settings

Applications > easyTravel Website > (...) Edit

2) Select Session and User action properties, and click Custom defined property and enter the following:

User Session Property Config

3) Click Save Property

It may take 5-10 mins to see results in Dynatrace because session properties are only available when the user session is completed.

You can view the user sessions that have the membershipstatus set by running the following USQL:

SELECT * FROM usersession WHERE stringProperties.membershipstatus IS NOT NULL ORDER BY startTime DESC

In this lab, we will create a session properties to expose business data Booking Total and Destination to Dynatrace

Booking Total

First get the CSS selector for the Booking Total field.

1) Assess the easyTravel homepage (the URL provied to you) 2) Seach for a destination e.g. Gold Coast and click Book Now

easyTravel Step 1

3) Login with username: janet and password: janet and click Next

easyTravel Step 2

4) Right click on the Round-trip ticket price $ value and click inspect

easyTravel Step 3

5) Right click on the td element and select Copy > Copy Selector

easyTravel Step 4

Second create the session property in Dynatrace.

1) Access the easyTravel application monitoring settings Applications > easyTravel > (...) Edit

2) Select Session and User action properties and click Custom defined property and enter the following:

You can view the user sessions that have the booking total value by running the following USQL:

SELECT * FROM usersession WHERE doubleProperties.bookingtotal IS NOT NULL ORDER BY startTime DESC

Trip Journey

For the trip Journey, back in easyTravel:

1) Right click on the Journey value and click inspect

easyTravel Step 3

2) Right click on the span element and select Copy > Copy Selector

easyTravel Step 4

Create the session property in Dynatrace.

1) Select Session and User action properties and click Custom defined property and enter the following:

You can view the user sessions that have the destination value by running the following USQL:

SELECT * FROM usersession WHERE stringProperties.journey IS NOT NULL ORDER BY startTime DESC

It may take 5-10 mins to see results in Dynatrace because session properties are only available when the user session is completed.

Creating a Basic USQL Dashboard

In this lab, we will create the following dashboard:

Basic Dashboard

Dashboard Components

The above dashboard has the following components:

Out of the Box Tiles:

USQL Tiles:

Single Value Tiles

Charts

In this lab, we will create the following dashboard:

Business Dashboard

Dashboard Components

The above dashboard has the following components:

1) User Behavior > easyTravel Website

2) Top conversion goals > easyTravel Website

3) Conversion goal > easyTravel Website > Sucessful Bookings

4) Bounce Rate > easyTravel Website

5) Key user actions > easyTravel Website

6) User Session Query - Revenue

    SELECT SUM(doubleProperties.bookingtotal) AS "Revenue (USD)" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") 

7) User Session Query - Total Revenue by Hour

   SELECT DISTINCT DATETIME(starttime, "HH:mm", "30m") as "Time",AVG(usersession.doubleProperties.bookingtotal) AS "Revenue (USD)" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") 

8) User Session Query - Revenue by Loyalty Status - Chart

   SELECT usersession.stringProperties.membershipstatus, SUM(usersession.doubleProperties.bookingtotal) AS "Revenue" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") and usersession.stringProperties.membershipstatus IS NOT NULL GROUP BY usersession.stringProperties.membershipstatus

9) User Session Query - Revenue by Loyalty Status - Table

   SELECT usersession.stringProperties.membershipstatus AS "Loyalty Status", SUM(usersession.doubleProperties.bookingtotal) AS "Revenue" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") and usersession.stringProperties.membershipstatus IS NOT NULL GROUP BY usersession.stringProperties.membershipstatus

10) User Session Query - Bookings by Trip Destination

    SELECT usersession.stringProperties.journey, SUM(usersession.doubleProperties.bookingtotal) FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") and usersession.stringProperties.journey IS NOT NULL GROUP BY usersession.stringProperties.journey    

11) User Session Query - Revenue by Loyalty Users

    SELECT userId AS "Customer", country AS "Origin Country", stringProperties.membershipstatus AS "Loyalty Status", SUM(doubleProperties.bookingtotal) AS "Revenue", AVG(doubleProperties.bookingtotal) AS "Average Trip Spend" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") and doubleProperties.bookingtotal IS NOT NULL AND CITY IS NOT NULL AND userId IS NOT NULL AND stringProperties.membershipstatus  IN ("Gold", "Platinum", "Silver") GROUP BY userId, country, stringProperties.membershipstatus ORDER BY sum(doubleProperties.bookingtotal) DESC

12) User Session Query - Revenue by Purchasing City

    SELECT city AS "Origin City", country AS "Origin Country", SUM(doubleProperties.bookingtotal) AS "Revenue", AVG(doubleProperties.bookingtotal) AS "Average Trip Spend" FROM usersession WHERE useraction.application="easyTravel Website" and (useraction.name="loading of page /orange-booking-finish.jsf") and doubleProperties.bookingtotal IS NOT NULL AND CITY IS NOT NULL GROUP BY city, country ORDER BY sum(doubleProperties.bookingtotal) DESC

In this lab, we will create a dashboard to display a basic sales funnel.

In the Dynatrace UI, create a new dashboard named "Sales Funnel" (Dashboards > Create Dashboard)

  1. Add the User Sessions Query to the dashboard and configure the tile

USQL Icon

  1. Enter the UQSL as follows

select count(*) as "Homepage Requests" from usersession where useraction.name = "loading of page /orange.jsf"

USQL

  1. Click on "Save Changes to dashboard"
  2. Repeat the above steps to create dashboard tiles for:

Review Page:

select count(*) as "Review Page Requests" from usersession where useraction.name="loading of page /orange.jsf" and useraction.name="loading of page /orange-booking-review.jsf"

Payment Page:

select count(*) as "Payment Page Requests" from usersession where useraction.name="loading of page /orange.jsf" and useraction.name="loading of page /orange-booking-review.jsf" and useraction.name="loading of page /orange-booking-payment.jsf"

Finish Page:

select count(*) as "Finish Page Requests" from usersession where useraction.name="loading of page /orange.jsf" and useraction.name="loading of page /orange-booking-review.jsf" and useraction.name="loading of page /orange-booking-payment.jsf" and useraction.name="loading of page /orange-booking-finish.jsf"

When you are finished your dashboard should look something like this:

Dashboard Basic Funnel

In this lab, we will create a dashsboard using the Dashboard API.

You will need an API token with the Read configuration and Write Configuration permissions for this session.

Dashboard API Permissions

Step-by-step Guide - Access API Explorer

In the Dynatrace dashboard, navigate to the Configuration API: Settings -> Integration -> Dynatrace API > Dynatrace API Explorer

Select Configuration API from the top right drop down menu.

Authorise ReadConfigToken (apiKey) and WriteConfigToken (apiKey) for this session.

Step-by-step Guide - Create Dashboard using API

  1. In the API list select Dashboards
  2. Select POST /dashboards

Dashboard API

  1. Select Try it Out
  2. The following json will create a dashboard. Copy the JSON into the Example Value field
{
  "dashboardMetadata": {
    "name": "Executive Overview Dashboard",
    "shared": false,
    "sharingDetails": {
      "linkShared": true,
      "published": false
    },
    "dashboardFilter": {
      "timeframe": "l_2_HOURS",
      "managementZone": null
    }
  },
  "tiles": [
    {
      "name": "Top web applications",
      "tileType": "APPLICATIONS_MOST_ACTIVE",
      "configured": true,
      "bounds": {
        "top": 494,
        "left": 0,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      }
    },
    {
      "name": "Overview",
      "tileType": "HEADER",
      "configured": true,
      "bounds": {
        "top": 0,
        "left": 0,
        "width": 304,
        "height": 38
      },
      "tileFilter": {
        "managementZone": null
      }
    },
    {
      "name": "Problems",
      "tileType": "OPEN_PROBLEMS",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 0,
        "width": 152,
        "height": 152
      },
      "tileFilter": {
        "managementZone": null
      }
    },
    {
      "name": "Service health",
      "tileType": "SERVICES",
      "configured": true,
      "bounds": {
        "top": 798,
        "left": 152,
        "width": 152,
        "height": 152
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": null,
      "chartVisible": true
    },
    {
      "name": "Host health",
      "tileType": "HOSTS",
      "configured": true,
      "bounds": {
        "top": 798,
        "left": 0,
        "width": 152,
        "height": 152
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": null,
      "chartVisible": true
    },
    {
      "name": "Application health",
      "tileType": "APPLICATIONS",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 152,
        "width": 152,
        "height": 152
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": null,
      "chartVisible": true
    },
    {
      "name": "World map",
      "tileType": "APPLICATION_WORLDMAP",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 380,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ],
      "metric": "APDEX"
    },
    {
      "name": "User behavior",
      "tileType": "SESSION_METRICS",
      "configured": true,
      "bounds": {
        "top": 342,
        "left": 380,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ]
    },
    {
      "name": "User breakdown",
      "tileType": "USERS",
      "configured": true,
      "bounds": {
        "top": 342,
        "left": 684,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ]
    },
    {
      "name": "Bounce rate",
      "tileType": "BOUNCE_RATE",
      "configured": true,
      "bounds": {
        "top": 342,
        "left": 988,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ]
    },
    {
      "name": "JavaScript errors",
      "tileType": "UEM_JSERRORS_OVERALL",
      "configured": true,
      "bounds": {
        "top": 646,
        "left": 380,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ]
    },
    {
      "name": "Resources",
      "tileType": "RESOURCES",
      "configured": true,
      "bounds": {
        "top": 646,
        "left": 988,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ],
      "metric": "ACTION_COUNT"
    },
    {
      "name": "Most used 3rd parties",
      "tileType": "THIRD_PARTY_MOST_ACTIVE",
      "configured": true,
      "bounds": {
        "top": 646,
        "left": 684,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ],
      "metric": "ACTION_COUNT"
    },
    {
      "name": "Live user activity",
      "tileType": "UEM_ACTIVE_SESSIONS",
      "configured": true,
      "bounds": {
        "top": 190,
        "left": 0,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      }
    },
    {
      "name": "Web application",
      "tileType": "APPLICATION",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 988,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ]
    },
    {
      "name": "World map",
      "tileType": "APPLICATION_WORLDMAP",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 684,
        "width": 304,
        "height": 304
      },
      "tileFilter": {
        "managementZone": null
      },
      "assignedEntities": [
        "APPLICATION-534A6A58D004195A"
      ],
      "metric": "SESSION_USERS"
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 0,
        "left": 380,
        "width": 1254,
        "height": 38
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "##[easyTravel Production Overview](#uemapplications/uemappmetrics;uemapplicationId=APPLICATION-534A6A58D004195A)"
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 266,
        "left": 1330,
        "width": 304,
        "height": 38
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "### [Hosts Overview](#newhosts)\n\n"
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 38,
        "left": 1330,
        "width": 304,
        "height": 38
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "###[Services Overview](#newservices)"
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 494,
        "left": 1330,
        "width": 304,
        "height": 38
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "### [Database Overview](#databases)"
    },
    {
      "name": "",
      "tileType": "SERVICES",
      "configured": true,
      "bounds": {
        "top": 76,
        "left": 1330,
        "width": 152,
        "height": 190
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": {
        "type": "SERVICE",
        "customName": "Java",
        "defaultName": "Java",
        "chartConfig": {
          "type": "TIMESERIES",
          "series": [],
          "resultMetadata": {}
        },
        "filtersPerEntityType": {
          "SERVICE": {
            "SERVICE_SOFTWARE_TECH": [
              "JAVA"
            ]
          }
        }
      },
      "chartVisible": true
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 722,
        "left": 1330,
        "width": 152,
        "height": 228
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "## Links\n---\n[Docker Overview](#docker)  \n[AWS Overview](#awses)  \n[Azure Overview](#azures)  \n[VMWare Overview](#vcenters)  \n[Network Overview](#networkoverview)"
    },
    {
      "name": "Markdown",
      "tileType": "MARKDOWN",
      "configured": true,
      "bounds": {
        "top": 722,
        "left": 1482,
        "width": 152,
        "height": 228
      },
      "tileFilter": {
        "managementZone": null
      },
      "markdown": "## Help\n---\n[Dynatrace Help](https://www.dynatrace.com/support/help/)  \n[Contact Support](https://www.dynatrace.com/support/contact-support/)  \n[What is Dynatrace?](https://www.dynatrace.com/support/help/get-started/what-is-dynatrace/)  \n[Dynatrace University](https://university.dynatrace.com/)  \n[Dynatrace Youtube](https://www.youtube.com/channel/UCcYJ-5q_AfmjQ4XTjTS0o3g)"
    },
    {
      "name": "",
      "tileType": "SERVICES",
      "configured": true,
      "bounds": {
        "top": 76,
        "left": 1482,
        "width": 152,
        "height": 190
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": {
        "type": "SERVICE",
        "customName": "Nginx Services",
        "defaultName": "Nginx Services",
        "chartConfig": {
          "type": "TIMESERIES",
          "series": [],
          "resultMetadata": {}
        },
        "filtersPerEntityType": {
          "SERVICE": {
            "SERVICE_SOFTWARE_TECH": [
              "NGINX"
            ]
          }
        }
      },
      "chartVisible": true
    },
    {
      "name": "",
      "tileType": "HOSTS",
      "configured": true,
      "bounds": {
        "top": 304,
        "left": 1330,
        "width": 304,
        "height": 190
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": {
        "type": "HOST",
        "customName": "AWS Hosts",
        "defaultName": "AWS Hosts",
        "chartConfig": {
          "type": "TIMESERIES",
          "series": [],
          "resultMetadata": {}
        },
        "filtersPerEntityType": {
          "HOST": {
            "HOST_VIRTUALIZATION": [
              "1"
            ]
          }
        }
      },
      "chartVisible": true
    },
    {
      "name": "",
      "tileType": "DATABASES_OVERVIEW",
      "configured": true,
      "bounds": {
        "top": 532,
        "left": 1330,
        "width": 304,
        "height": 190
      },
      "tileFilter": {
        "managementZone": null
      },
      "filterConfig": {
        "type": "DATABASE",
        "customName": "Databases",
        "defaultName": "Databases",
        "chartConfig": {
          "type": "TIMESERIES",
          "series": [],
          "resultMetadata": {}
        },
        "filtersPerEntityType": {}
      },
      "chartVisible": true
    }
  ]
}
  1. Select Execute, to create your browser test.

The server response should be response code 201 with a response body like the following:

{
  "id": "8f721746-8e2b-40fe-bd3b-61c1657d59df",
  "name": "Executive Overview Dashboard"
}

Navigate back to the Dynatrace dashboards. The dashboard should look something like this:

Dashboard

Go to the BizOps Configurator URL.

Follow the Step 2 instructions on the BizOps Prereqs page to setup your API Token.

Click on Begin and provide your tenant URL and API token.
Please clone the repository or create a Personal Access Token if you plan to use the BizOps Configurator to avoid hitting GitHub API limits

BizOpsConfigurator

Click on Deploy Tenant Overview and select the BizOps Template

BizOpsConfigurator

Click on Deploy App Overview and select Easytravel for the dropdown for both App Overview and Release overview. Click Upload

BizOpsConfigurator

Click on Deploy Journey, use "Book Travel" under Journey Name and select cartamount for KPI with Revenue as name.

BizOpsConfigurator

Drag the Key User Actions to the funnel to build out the funnel steps.

BizOpsConfigurator

Check back in Dynatrace to see the Book Travel Overview funnel dashboard.

BizOpsConfigurator

In this lab is split into two sections, the first section generates an API token request URL we can use the fetch data from Dynatrace. The second section uses this URL to import data into Excel. If you already have an API token and URL then jump stright to the part of this lab

Section 1 - Create API Token & Timeseries API Call

Create API Token

First we need to create a API token.

In the Dynatrace dashboard, navigate to the Configuration API: Settings -> Integration -> Dynatrace API

  1. Click Generate token

Generate Token

  1. Enter a name for your token and select the appropriate access switches for the token, then click Generate.

In this lab we will only need Access problem and event feed, metrics and topology

Add Token Name

  1. Click the down arrow (under the edit column) to display your token. Take note of the token for later use.

Add Token Name

Access API Explorer

In the Dynatrace dashboard, navigate to the Configuration API: Settings -> Integration -> Dynatrace API

  1. Click Dynatrace API Explorer

Ensure you are using Environment API v2 (top right corner of the screen)

  1. Click Authorize
  2. Enter your API token under the DataExport (apiKey) and click Authorise

Authorise API with Token

  1. Click Close

Authorise API

Timeseries API Call

  1. In the API list select Metrics
  2. Select GET /metrics/query
  3. Click Try it out

Tryout Timeseries API

  1. Enter the following parameters:
    • metricSelector: builtin:apps.web.apdex.userType:filter(eq(User type,Real users)):names
    • resolution: 5m
    • from: now-4h
  2. Change Response content type to text/csv; header=present; charset=utf-8

Tryout Timeseries API

  1. Click Execute. If successful the result should be shown looking something like this:

API Result

Copy the Request URL for use in the next section.

Section 2 - Create API Token & Timeseries API Call

  1. Open Excel and create a new workbook.
  2. Select: Data > From Web
  3. Select Advanced
  4. Enter your Request URL in URL Parts
  5. Add the following HTTP request header parameter then click OK and Connect Accept text/csv; header=present; charset=utf-8 Authorization Api-Token

API Result

  1. Click Load

API Result

  1. You data sould be imported

API Result

We hope you enjoyed this lab and found it useful. We would love your feedback!

How was your overall experience with this lab?

Excellent Good Average Fair Poor

What did you benefit most from this lab?

Learning Digital Business Analytics User Session Properties setup Understanding BizOps Configurator Advanced Dashboard Configurator Setup

How likely are you to recommend this lab to a friend or colleague?

Very Likely Moderately Likely Neither Likely nor unlikely Moderately Unlikely Very Unlikely