Skip to content

Convert counts.web_ide_views to Internal events

Problem

counts.web_ide_views is currently using the deprecated Redis Total Count.

We want to migrate it to Internal Events, but need to make sure the counting is not disrupted by that change.

Desired Outcome

We converted counts.web_ide_views to internal_events without a disruption to the event counting process.

Proposed solution

As discussed in #424892 (comment 1607772683) we could add a redis_key to the metric definition for such conversions to not disrupt the transition.

How to verify

Count of the metric counts.web_ide_views for SaaS continues as normal.

SQL query:

SELECT
        date_trunc('week', ping_created_at),
        metrics_path,
        metric_value,
        has_timed_out --if metric timed out, the value will be set to 0
      FROM common.fct_ping_instance_metric_rolling_6_months --model limited to last 6 months for performance
      WHERE dim_instance_id = 'ea8bf810-1d6f-4a6a-b4fd-93e8cbd8b57f' --SaaS instance, both production and staging installations
      AND metrics_path = 'counts.web_ide_views' --set to metric of interest
      ORDER BY ping_created_at DESC
Edited by Sebastian Rehm