Hi everyone! Has someone an example project that c...
# integration-dbt
l
Hi everyone! Has someone an example project that contains a job that does some generic python computation, then triggers a dbt materialization, and after the materialization ends successfully, another python computation is triggered? 🌈
b
Hey Lorenzo, we achieve that via
@multi_assets
annotations and correct
ins
and
outs
parameters so our flow is
@multi_asset [Meltano CLI for EL]
--->
@multi_asset[Pure Python Verification]
-->
@multi_asset[Dbt Transformations]
l
Wow thanks @Binoy Shah, so from what i see in the docs the idea would be to define a single block with this decorator and then make it do all the steps inside the multi_asset block?
b
That’s how we achieve it.. actual code.. with some “secret” sauce removed
❤️ 1
l
Thank you so much @Binoy Shah!! 🙏Now I'll try to adapt it to my project. 🌈
o
hi @Lorenzo! there's also a complete example project here, showing how to combine specifically dbt and python, as well as a full tutorial which walks through setting up assets upstream and downstream of a dbt project 🙂
l
Thank you @owen 😄. I did try the examples that are on the repo but I didn't find a project similar to what my PM is asking for, and I am starting to think that it's not actually possible to implement in the way he's thinking. What I am trying to build is an hybrid. I'll attach a picture because it would be hard to explain 😂
o
what would those start/stop ops being doing? I think in most cases, it would be more ergonomic to define them as assets than ops, but it definitely depends on the exact use case.
❤️ 1
l
Thanks @owen. 🙌🏻 Yes, I ended up defining them as assets. They are going to do different operations, like sending an email or message, launching a query, writing a log file...