From f500ca9c9e25932ac05178939e17b2c057cc6b4d Mon Sep 17 00:00:00 2001 From: Harshal Sheth Date: Tue, 6 Dec 2022 15:10:35 -0500 Subject: [PATCH] fix(ingest/snowflake): support domains for snowflake schema containers --- .../src/datahub/ingestion/source/snowflake/snowflake_v2.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/metadata-ingestion/src/datahub/ingestion/source/snowflake/snowflake_v2.py b/metadata-ingestion/src/datahub/ingestion/source/snowflake/snowflake_v2.py index 4c96e0fb32edb..cfef2c9f35f91 100644 --- a/metadata-ingestion/src/datahub/ingestion/source/snowflake/snowflake_v2.py +++ b/metadata-ingestion/src/datahub/ingestion/source/snowflake/snowflake_v2.py @@ -922,6 +922,8 @@ def gen_database_containers( def gen_schema_containers( self, schema: SnowflakeSchema, db_name: str ) -> Iterable[MetadataWorkUnit]: + domain_urn = self._gen_domain_urn(f"{db_name}.{schema.name}") + schema_container_key = self.gen_schema_key( self.snowflake_identifier(db_name), self.snowflake_identifier(schema.name), @@ -939,6 +941,7 @@ def gen_schema_containers( description=schema.comment, sub_types=[SqlContainerSubTypes.SCHEMA], parent_container_key=database_container_key, + domain_urn=domain_urn, external_url=self.get_external_url_for_schema(schema.name, db_name) if self.config.include_external_url else None,