Skip to content

Commit

Permalink
Add feature flag for view defintions (#10914)
Browse files Browse the repository at this point in the history
Co-authored-by: Ethan Cartwright <[email protected]>
  • Loading branch information
ethan-cartwright and ethan-cartwright authored Jul 16, 2024
1 parent bb1ba09 commit 12ee485
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,11 @@ class SnowflakeV2Config(
description="If enabled, populates the snowflake usage statistics. Requires appropriate grants given to the role.",
)

include_view_definitions: bool = Field(
default=True,
description="If enabled, populates the ingested views' definitions.",
)

include_technical_schema: bool = Field(
default=True,
description="If enabled, populates the snowflake technical schema and descriptions.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -753,7 +753,11 @@ def gen_dataset_workunits(
view_properties_aspect = ViewProperties(
materialized=table.materialized,
viewLanguage="SQL",
viewLogic=table.view_definition,
viewLogic=(
table.view_definition
if self.config.include_view_definitions
else ""
),
)

yield MetadataChangeProposalWrapper(
Expand Down

0 comments on commit 12ee485

Please sign in to comment.