dbt-labs / terraform-provider-dbtcloud

dbt Cloud Terraform Provider
https://registry.terraform.io/providers/dbt-labs/dbtcloud
MIT License
82 stars 19 forks source link

Feature - Add support for dbt cloud artefacts (source freshness and docs) #100

Closed b-per closed 1 year ago

b-per commented 1 year ago

Closes #98

This is my attempt at adding links to source freshness and docs jobs (which I called artefacts) at the project level. I also updated the data source to contain the job ids for docs and source freshness.

Behind the scenes, the implementation is quite close to the project_connection one, calling the xxxProject() methods.

One thing that I wasn't sure how to manage properly was to get the ids set to nil instead of 0 when there is no job_id defined.

This is still WIP but I'd be keen for any feedback until now.

Still to be done:

b-per commented 1 year ago

Added some acceptance tests (they ran OK for me) and updated the docs image

I am not a huge fan of the fact that if a freshness or docs job is not setup it shows with the id 0 in the state (when it should actually be null) but otherwise it all seems to be working fine!

b-per commented 1 year ago

Hi @GtheSheep ! I am not sure if you saw this PR so this is just a quick ping 😃

GtheSheep commented 1 year ago

hey @b-per! sorry for the slow response, have chucked a couple of comments on here now when you get a chance, thanks again 😸

b-per commented 1 year ago

Thanks for the review 👍 I have added additional context to your comments!

b-per commented 1 year ago

@GtheSheep , no rush, but I'd need you to approve the workflow for this. Let me know if you have any other feedback/question after the ones I posted last time.

GtheSheep commented 1 year ago

@b-per - sorry, forgot about this! will take a look this week and test/ merge

GtheSheep commented 1 year ago

/ok-to-test sha=8e68bcd