<@U088WCP3B4P> Hey guys, all we pretty much do car...
# ask-elementary-ai
d
@kapa.ai Hey guys, all we pretty much do care about since we use dbt Cloud is test run results being stored in DW. Are the any config variables to make sure dbt-artifacts is not invoked in runs? There seems to be performance drift.
k
A message from kapa.ai
Yes, you can configure Elementary to only store test run results and avoid invoking the dbt-artifacts models, which can help with performance. To do this, you should set the following variables in your
dbt_project.yml
or via the CLI:
Copy code
yaml vars:   disable_dbt_artifacts_autoupload: true   disable_dbt_invocation_autoupload: true   disable_run_results: false   disable_tests_results: false
-
disable_dbt_artifacts_autoupload: true
will prevent the metadata models (like
dbt_models
,
dbt_sources
, etc.) from being updated. -
disable_dbt_invocation_autoupload: true
will prevent invocation metadata from being uploaded. - Keeping
disable_run_results
and
disable_tests_results
as
false
ensures that test run results are still stored in your data warehouse. You can also set these variables conditionally based on your environment if needed. For example, to only enable artifact uploads in production:
Copy code
yaml vars:   disable_dbt_artifacts_autoupload: "{{ target.name != 'prod' }}"   disable_dbt_invocation_autoupload: "{{ target.name != 'prod' }}"
This approach is commonly used to improve performance, especially in dbt Cloud or CI environments where only test results are needed and metadata uploads are unnecessary. Several users have reported significant performance improvements by disabling artifact uploads and only running them on deployment or as needed, rather than on every run or test execution [Disable on-run-end hooks](https://docs.elementary-data.com/dbt/on-run-end_hooks#can-i-disable-the-on-run-end-hooks?), [Slack thread: performance drift](https://slack.com/archives/C02CTC89LAX/p1717515678662739). If you want to be extra sure, you can also pass these variables directly in your dbt Cloud job or CLI command:
Copy code
dbt run --vars '{"disable_dbt_artifacts_autoupload": true, "disable_dbt_invocation_autoupload": true}'
This will ensure that only test run results are stored, and the dbt-artifacts models are not invoked, minimizing performance overhead.