Skip to content

Add snowplow tracking to compliance center

What does this MR do and why?

Add snowplow events to the Compliance Center in order to be able to better understand how customers use the features in this dashboard.

This doubles as an example of how to add snowplow events for the compliance team.

  • Add snowplow tracking to tab clicks and export buttons.
  • This showcases two different kinds tracking approaches
    • data-attributes based tracking can be used for elements that emit a click event
    • using the Tracking mixin for other custom elements

Screenshots or screen recordings

Events captured to local snowplow micro to show events being triggered and sent:

Before After
an empty void Screenshot_2023-08-01_at_17.20.06
an empty void Screenshot_2023-08-01_at_17.19.06
an empty void Screenshot_2023-08-01_at_17.18.17

How to set up and validate locally

  1. Enable: snowplow on your instance
    1. If you have https enabled locally you will need to switch back to the http config first
  2. Setup: SnowPlow Micro
  3. Visit: Compliance Center for one of your groups (you will need to have an active license that supports the dashboard)
  4. Click: any tab or export button
  5. Visit: http://localhost:9001/micro/good (if you customized the port or host adapt this URL accordingly)
  6. View: the output and search for click_export or click_report_tab to find the events you triggered

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports