Migrating Azure Data Factory’s Snowflake Connector from Legacy to latest V2 by info.odysseyx@gmail.com October 22, 2024 written by info.odysseyx@gmail.com October 22, 2024 0 comment 11 views 11 We recently announced a new updated V2 of our popular Snowflake connector in Azure Data Factory. The new connector promises better performance and security. The new V2 connector supports pipelines and data flows and comes with the new Go-based Snowflake driver. Differences between legacy connectors and V2 connectors The V2 connector offers improvements in performance and security. The main differences between legacy connectors and V2 connectors are: Snowflake (V2) Snowflake (Legacy) ODBC driver Go to Driver Supports basic and key pair authentication. Supports basic authentication. Script parameters are not currently supported in script activities. As an alternative, utilize dynamic expressions for script parameters. Script activities support script parameters. Supports BigDecimal in lookup activities. NUMBER types defined in Snowflake are displayed as strings in lookup activities. BigDecimal is not supported in Lookup activities. Connection parameters include: account, storage, database, outlineand role The connection parameter is the connection string. Additional connection properties are not supported. Additional connection properties are supported. KeyVault can only store password/key pair keys. You can store passwords and connection strings in KeyVault. The V2 version offers several enhancements over the legacy version, including future features such as autoscaling, multi-availability, static IPs, improved storage consolidation support, and Iceberg support. For more information connector documentation. Deprecation of legacy connector support Snowflake Legacy Connector ends support on October 31stcastleWhen support ends in 2024, the connector will be considered deprecated and will no longer be supported. If you want to continue using your connector and experience new enhancements, we recommend upgrading your connector to the new V2 connector. read official announcement To know more. Migrate from Legacy to V2 Connector The steps required to update from Legacy to V2 connector include the following process: Check whether script parameters are being used. If so, modify it to use dynamic expressions. Check if additional connection parameters are being used If so, those parameters cannot be applied to the new connector. Update services connected to V2 connectors Update dataset to V2 dataset Connected service updates: Below is a typical example of a linked service using parameters and basic authentication. legacyV2 You need to change the connector version to V2. In your connection string, you need to update the type attribute to include the following: "typeProperties": { "authenticationType": "Basic", "accountIdentifier": "@{linkedService().accountIdentifier}", "user": "@{linkedService().user}", "database": "@{linkedService().database}", "warehouse": "@{linkedService().warehouse}", "encryptedCredential": "" } Dataset update: You will need to update your dataset to include V2 of the connector. Update property type from snowflake table to Snowflake V2 Table. Update definition file: Linked services and datasets can be updated through Git. To update linked services, you can use the following steps: Create a new branch from the main branch Update definition files Connection and pipeline testing Give a pull-request and merge it with the main branch. All other branches must be pulled from this branch, or the branches must be manually changed to match the definition. Collect the data factory list using the legacy connector: If you have a large environment and need to find a list of data factories that use legacy connectors, you can use PowerShell to find them. This program will run for a long time depending on the number of resources. You can access this code: gist. Verification with Snowflake query history: Queries generated by Data Factory users can be validated in Snowflake to determine if they are generated by a legacy or V2 connector. SELECT DISTINCT CLIENT_APPLICATION_ID, USER_NAME FROM SNOWFLAKE.ACCOUNT_USAGE.SESSIONS WHERE CREATED_ON > DATEADD(DAY, -1, CURRENT_TIMESTAMP) // OPTIONAL: FILTER BY TIME AND USER_NAME = '' // THE USER THAT IS CONFIGURED IN DATA FACTORY ORDER BY CLIENT_APPLICATION_ID; Legacy connectors have their versions after “ODBC”, and V2 connectors have their versions after “GO”. If you only want to see connections coming from ODBC, you can filter the client_application_id column. SELECT DISTINCT CLIENT_APPLICATION_ID, USER_NAME FROM SNOWFLAKE.ACCOUNT_USAGE.SESSIONS WHERE CREATED_ON > DATEADD(DAY, -1, CURRENT_TIMESTAMP) // OPTIONAL: FILTER BY TIME AND USER_NAME = '' // THE USER THAT IS CONFIGURED IN DATA FACTORY AND CLIENT_APPLICATION_ID LIKE '%ODBC%' // FILTER BY ODBC FOR LEGACY CONNECTOR ORDER BY CLIENT_APPLICATION_ID; Best practices: You can apply the following best practices to Data Factory to make migrating your connectors easier. Using Git for version control in Data Factory Create a separate branch to merge with the main branch and other branches to manage only connected services without pipelines/artifacts. Updated username/password based authentication to KeyPair authentication for increased security Store password/key pair keys using Key Vault Test your connector on a specific development environment/branch before pushing it to the main branch. We encourage you to try our new and improved connector. If you’re having trouble migrating or need help with: Source link Share 0 FacebookTwitterPinterestEmail info.odysseyx@gmail.com previous post The latest enhancements in Microsoft Authenticator next post IAMCP Profiles in Partnership Podcast Ep 3 | Personal Connections: The Key to Digital Partnerships You may also like Bots now dominate the web and this is a copy of a problem February 5, 2025 Bots now dominate the web and this is a copy of a problem February 5, 2025 Bots now dominate the web, and this is a problem February 4, 2025 DIPSEC and HI-STECS GLOBAL AI Race February 4, 2025 DEPSEC SUCCESS TICTOKE CAN RUNNING TO PUPPENSE TO RESTITE January 29, 2025 China’s AI Application DEPSEC Technology Spreads on the market January 28, 2025 Leave a Comment Cancel Reply Save my name, email, and website in this browser for the next time I comment.