-
Notifications
You must be signed in to change notification settings - Fork 25
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
Update api_calls to extract_summary #138
Conversation
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.
looks great to me! just minor requests but this is approved
@@ -63,7 +80,7 @@ connector_event_counts as ( | |||
|
|||
spine as ( | |||
|
|||
{% if execute %} | |||
{% if execute and flags.WHICH in ('run', 'build') %} |
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.
Could you note in the "under the hood" section of the CHANGELOG that this release supports dbt compile
on a new schema before dbt run
due to the above change?
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.
Yes, updated!
@@ -78,7 +95,7 @@ spine as ( | |||
{{ fivetran_utils.fivetran_date_spine( | |||
datepart = "day", | |||
start_date = "cast('" ~ first_date[0:10] ~ "' as date)", | |||
end_date = dbt.dateadd("week", 1, dbt.date_trunc('day', dbt.current_timestamp_backcompat() if target.type != 'sqlserver' else dbt.current_timestamp())) | |||
end_date = dbt.dateadd("week", 1, dbt.date_trunc('day', dbt.current_timestamp())) |
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.
super duper minor -- would you mind updating the parallel line in the row_count__connector_daily_events test?
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.
Good call. updated!
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.
Thanks @fivetran-jamie made the updates!
@@ -78,7 +95,7 @@ spine as ( | |||
{{ fivetran_utils.fivetran_date_spine( | |||
datepart = "day", | |||
start_date = "cast('" ~ first_date[0:10] ~ "' as date)", | |||
end_date = dbt.dateadd("week", 1, dbt.date_trunc('day', dbt.current_timestamp_backcompat() if target.type != 'sqlserver' else dbt.current_timestamp())) | |||
end_date = dbt.dateadd("week", 1, dbt.date_trunc('day', dbt.current_timestamp())) |
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.
Good call. updated!
@@ -63,7 +80,7 @@ connector_event_counts as ( | |||
|
|||
spine as ( | |||
|
|||
{% if execute %} | |||
{% if execute and flags.WHICH in ('run', 'build') %} |
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.
Yes, updated!
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.
LGTM with one small question/request around a comment from a previous update and if we should change it.
# Fivetran Platform dbt Package ([Docs](https://fivetran.github.io/dbt_fivetran_log/)) | ||
|
||
<p align="left"> |
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.
Thanks for making this change as well!
where event_subtype in ( | ||
'api_call', 'extract_summary', 'records_modified', 'create_table', 'alter_table', | ||
'create_schema', 'change_schema_config') -- all schema changes |
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.
Small note that I know isn't related to your changes directly, but is it accurate to have the comment all schema changes
in this filter? For example, api_call
and extract_summary
are not inherently schema changes and we make this clear in the below case when
statement where we categorize perform the following:
when event_subtype in ('create_table', 'alter_table', 'create_schema', 'change_schema_config') then 'schema_change'
If this is true, can we change this comment to be all relevant event subtypes
or something along those lines.
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.
Makes sense--updated!
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.
PR Overview
This PR will address the following Issue/Feature:
extract_summary
event instead of currently-being-deprecatedapi_call
#137This PR will result in the following new package version:
Please provide the finalized CHANGELOG entry which details the relevant changes included in this PR:
PR Checklist
Basic Validation
Please acknowledge that you have successfully performed the following commands locally:
Before marking this PR as "ready for review" the following have been applied:
Detailed Validation
Please share any and all of your validation steps:
Updated seed data to make sure the values for
extract_summary
are pulled through.dbt_fivetran_log/integration_tests/seeds/log.csv
Lines 33 to 34 in 89a3650
Consistency tests pass
If you had to summarize this PR in an emoji, which would it be?
💃