Skip to content

Commit

Permalink
Merge pull request #16 from get-select/add_thread_id
Browse files Browse the repository at this point in the history
Add thread
  • Loading branch information
NiallRees authored Jun 29, 2023
2 parents 0d5c732 + 478aa41 commit 31c2ae7
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 3 deletions.
7 changes: 7 additions & 0 deletions .changes/2.3.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
## dbt-snowflake-query-tags 2.3.0 - June 29, 2023

### Features

- Add thread_id to query tag ([#16](https://github.com/get-select/dbt-snowflake-query-tags/pull/16))


8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html),
and is generated by [Changie](https://github.com/miniscruff/changie).

## dbt-snowflake-query-tags 2.3.0 - June 29, 2023

### Features

- Add thread_id to query tag ([#16](https://github.com/get-select/dbt-snowflake-query-tags/pull/16))



## dbt-snowflake-query-tags 2.2.0 - June 23, 2023

### Features
Expand Down
2 changes: 1 addition & 1 deletion dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
name: 'dbt_snowflake_query_tags'
version: '2.2.0'
version: '2.3.0'
config-version: 2
2 changes: 1 addition & 1 deletion macros/query_comment.sql
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{%- set comment_dict = {} -%}
{%- do comment_dict.update(
app='dbt',
dbt_snowflake_query_tags_version='2.0.1',
dbt_snowflake_query_tags_version='2.3.0',
dbt_version=dbt_version,
project_name=project_name,
target_name=target.name,
Expand Down
9 changes: 8 additions & 1 deletion macros/query_tags.sql
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,16 @@

{%- do tag_dict.update(
app='dbt',
dbt_snowflake_query_tags_version='2.0.1',
dbt_snowflake_query_tags_version='2.3.0',
) -%}

{% if thread_id %}
{%- do tag_dict.update(
thread_id=thread_id
) -%}
{% endif %}


{# We have to bring is_incremental through here because its not available in the comment context #}
{% if model.resource_type == 'model' %}
{%- do tag_dict.update(
Expand Down

0 comments on commit 31c2ae7

Please sign in to comment.