-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feature/reduce-date-spine #57
Changes from all commits
6420db8
ee302b9
2fb7542
7596a42
b32f08c
4cfb06d
e366245
ef10414
f98ea25
e1952f6
6875405
04754a2
285ab98
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
config-version: 2 | ||
name: 'mixpanel' | ||
version: '0.11.0' | ||
version: '0.12.0' | ||
require-dbt-version: [">=1.3.0", "<2.0.0"] | ||
models: | ||
mixpanel: | ||
|
@@ -10,17 +10,10 @@ models: | |
vars: | ||
mixpanel: | ||
event_table: "{{ source('mixpanel', 'event') }}" | ||
mixpanel__event_frequency_limit: 1000 | ||
date_range_start: '2010-01-01' # mostly global filter placed on mixpanel__event to limit the date range. does not apply to stg_mixpanel__event and stg_mixpanel__user_first_event | ||
# global_event_filter: # global filter to place on this whole package in order to remove noise from events | ||
event_custom_columns: [] # any custom column names in the source mixpanel.event table to include in mixpanel__event | ||
# - name: "app_version" <- example format | ||
# alias: "app_version_alias" | ||
# transform_sql: "cast(app_version as string)" | ||
event_properties_to_pivot: [] # list of events in mixpanel__event.event_properties (in the source table, event.properties) to pivot out into columns in mixpanel__event | ||
|
||
sessionization_inactivity: 30 # number of minutes it takes for a session to timeout due to inactivity | ||
# session_event_criteria: # filter to place on events in order to qualify for sessionization | ||
sessionization_trailing_window: 3 # number of hours to look back at for each mixpanel__sessions run. this allows you to sessionize events that arrive late without requiring a full refresh | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like it's really appropriate to remove this since we essentially deprecated a few releases ago. |
||
session_passthrough_columns: [] # choose event columns to pass through to mixpanel__sessions (values taken from first event of session) | ||
mixpanel_sources: [] |
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
_file,_line,_fivetran_id,event_id,name,time,distinct_id,properties,insert_id,mp_processing_time_ms,_fivetran_synced,screen_width,wifi,app_release,app_version,os,mp_device_model,city,os_version,mp_country_code,lib_version,manufacturer,radio,carrier,screen_height,app_build_number,model,region,app_version_string,mp_lib,initial_referring_domain,device_id,referrer,current_url,browser,browser_version,initial_referrer,search_engine,referring_domain,bluetooth_version,has_nfc,brand,has_telephone,screen_dpi,google_play_services,had_persisted_distinct_id,bluetooth_enabled,ios_ifa,device,mp_keyword,distinct_id_before_identity,ae_session_length,insert_id_ | ||
sample_events.csv,10008,k4G7CSSjxr2mRtBxpVCxKHx+E8c=,9406000,plays,2020-08-01 19:16:46,9e308c27-42ab-57af-beef-555708cde092,"{""Operating System"": ""Roku"",""title"": ""spongebob"",""user_id"": ""114521"",""video_id"": 5279}",pnreuCmtCqgcDgkCaFhymwDgmwajggzaiDdn,406572,2020-08-07 08:59:49,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
sample_events.csv,10009,tUc30K5Umuk03m8f3Vo3Np0uCAA=,1744000,playthrough_25,2020-08-01 11:35:44,622b169c-2187-5121-85e6-e5960b2512e3,"{""Operating System"": ""Roku"",""title"": ""rupaul's drag race"",""user_id"": ""129997"",""video_id"": 6369}",vqrpqghnlgcCzfjBmdsjcgqgDtwchbxAkuFu,744380,2020-08-07 08:58:02,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
_file,_line,_fivetran_id,event_id,name,time,distinct_id,properties,insert_id,mp_processing_time_ms,_fivetran_synced,screen_width,wifi,app_release,app_version,os,mp_device_model,city,os_version,mp_country_code,lib_version,manufacturer,radio,carrier,screen_height,app_build_number,model,region,app_version_string,mp_lib,initial_referring_domain,device_id,referrer,current_url,browser,browser_version,initial_referrer,search_engine,referring_domain,bluetooth_version,has_nfc,brand,has_telephone,screen_dpi,google_play_services,had_persisted_distinct_id,bluetooth_enabled,ios_ifa,device,mp_keyword,distinct_id_before_identity,ae_session_length | ||
sample_events.csv,10008,k4G7CSSjxr2mRtBxpVCxKHx+E8c=,9406000,plays,2020-08-01 10:16:46,9e308c27-42ab-57af-beef-555708cde092,"{""Operating System"": ""Roku"",""title"": ""spongebob"",""user_id"": ""114521"",""video_id"": 5279}",pnreuCmtCqgcDgkCaFhymwDgmwajggzaiDdn,406572,2020-08-07 08:59:49,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
sample_events.csv,10009,tUc30K5Umuk03m8f3Vo3Np0uCAA=,1744000,playthrough_25,2020-08-01 11:35:44,622b169c-2187-5121-85e6-e5960b2512e3,"{""Operating System"": ""Roku"",""title"": ""rupaul's drag race"",""user_id"": ""129997"",""video_id"": 6369}",vqrpqghnlgcCzfjBmdsjcgqgDtwchbxAkuFu,744380,2020-08-07 08:58:02,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
sample_events.csv,10010,tUc30K5Umuk03m8f3Vo3Np0uCAB=,1744000,playthrough_25,2024-02-02 08:58:02,622b169c-2187-5121-85e6-e5960b2512e3,"{""Operating System"": ""Roku"",""title"": ""rupaul's drag race"",""user_id"": ""129997"",""video_id"": 6369}",vqrpqghnlgcCzfjBmdsjcgqgDtwchbxAkuFu,744380,2024-01-31 08:58:02,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
new.csv,10011,tUc30K5Umuk03m8f3Vo3Np0uCAR=,1744001,playthrough_29,2024-01-31 08:58:02,622b169c-2187-5121-85e6-e5960b2512e7,"{""Operating System"": ""Roku"",""title"": ""spongebob"",""user_id"": ""129998"",""video_id"": 6367}",vqrpqghnlgcCzfjBmdsjcgqgDtwchbxAkuGu,744380,2024-01-31 08:58:02,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, | ||
new.csv,100121,tUc30K5Umuk03m8f3Vo3Np0uCAT=,1744001,playthrough_30,2025-02-27 08:58:02,622b169c-2187-5121-85e6-e5960b2512e7,"{""Operating System"": ""Roku"",""title"": ""spongebob"",""user_id"": ""129998"",""video_id"": 6367}",vqrpqghnlgcCzfjBmdsjcgqgDtwchbxAkuGu,744380,2024-01-31 08:58:02,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, |
This file was deleted.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should the default date '2010-01-01' in line 28 also be removed? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I considered it, but it should stay. The issue with the date spine was that it internally generates all dates back to 2010 even if there weren't records that went back that far, whereas this model only references existing records. We need a default value of some sort but I wanted to avoid pinging the source and incurring costs if we didn't need to. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Gotcha! Thanks for explaining! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd also recommend adding an under the hood piece detailing why we're removing the variable declarations in the dbt_project.yml. Mainly for our reference in the future, but also good to callout since that may look like a big change, when it's really not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated!