cal-itp / data-infra

Cal-ITP data infrastructure
https://docs.calitp.org/data-infra
GNU Affero General Public License v3.0
44 stars 12 forks source link

Create view of Benefits events that pre-filters the app offline period #1411

Closed thekaveman closed 7 months ago

thekaveman commented 2 years ago

Is your feature request related to a problem? Please describe.

As a Metabase user, I would like a view of Benefits events that pre-filters the "application offline period", so that I can more easily analyze and visualize relevant metrics and not duplicate work.

Describe the solution you'd like

Another view along the lines of views.amplitude_benefits_events which is more or less defined as:

select *
from views.amplitude_benefits_events
where (views.amplitude_benefits_events.client_event_time < timestamp "2022-01-20 08:00:00 GMT"
    or views.amplitude_benefits_events.client_event_time > timestamp "2022-02-01 07:59:59 GMT")

Describe alternatives you've considered

I am currently doing this in a giant Question SQL query in Metabase; this pattern could be repeated for each Question/viz we create.

Additional context

Following on from #960

The "application offline period" started with an internal pentest on January 20, 2022 and lasted through to February 1, 2022 when the application was back online and available for users. Because a large portion of the event data from January 20 was due to the pentesting, it makes sense to exclude this day entirely.

This is how our current Amplitude charts work, using what they call a "Drop Filter" applied at the project level:

image

thekaveman commented 7 months ago

Not a priority now that Metabase will have a better dataset.