Skip to content
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

status_analytics : adding dbt transformation #27

Merged
merged 3 commits into from
Mar 31, 2025
Merged

status_analytics : adding dbt transformation #27

merged 3 commits into from
Mar 31, 2025

Conversation

c200bzh
Copy link
Contributor

@c200bzh c200bzh commented Mar 28, 2025

Status Analytics: Adding DBT transformation to the DAG for Mixpannel and Google play store

@c200bzh c200bzh added the enhancement New feature or request label Mar 28, 2025
@c200bzh c200bzh requested a review from a team March 28, 2025 12:14
@c200bzh c200bzh self-assigned this Mar 28, 2025
@c200bzh
Copy link
Contributor Author

c200bzh commented Mar 28, 2025

Need Mixpannel DBT transformation to be merged first :

Copy link
Contributor

@apentori apentori left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid having to many different dbt run, let's look at a way to group then, else with the other data source it's going to get messier : https://docs.getdbt.com/reference/node-selection/yaml-selectors#difference-between---select-and---selector

Comment on lines 76 to 90
# Launch DBT transformation for Mixpanel models
dbt_transform_mixpanel = BashOperator(
task_id='dbt_run_models_mixpanel',
bash_command='dbt run --select mixpannel',
env=INTERNAL_ENV,
append_env=True
)

# Launch DBT transformation for Google Play Store models
dbt_transform_playstore = BashOperator(
task_id='dbt_run_models_playstore',
bash_command='dbt run --select google_store',
env=INTERNAL_ENV,
append_env=True
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's look into the --selectors usage to group mixpanel and google_store, wdyt ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can just run the models in the same command, I just did a commit for this

@apentori
Copy link
Contributor

Also please add reference to the issue, like that:

@c200bzh
Copy link
Contributor Author

c200bzh commented Mar 28, 2025

To avoid having to many different dbt run, let's look at a way to group then, else with the other data source it's going to get messier : https://docs.getdbt.com/reference/node-selection/yaml-selectors#difference-between---select-and---selector

We can try in a way it is cleaner but it also gives less visibility on what we are running

@apentori
Copy link
Contributor

We can try in a way it is cleaner but it also gives less visibility on what we are running

Well we don't know which exact models are run when looking at Airflow Dags, but when looking at DBT, we will know that the models are linked.
I think that's better for visibity, but if you prefer to have a list of tasks for runing dbt, that;s good for me also

@c200bzh c200bzh merged commit 03644ae into test Mar 31, 2025
@c200bzh c200bzh deleted the dbt branch March 31, 2025 08:37
apentori pushed a commit that referenced this pull request Mar 31, 2025
* status_analytics : adding dbt transformation for mixpannel and google play store

* status_analytics : run the dbt models in the same command

* Add selector to group the dbt run of analytics models

Signed-off-by: Alexis Pentori <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants