About this repository
The Purview Custom Types Tool is a solution accelerator for supporting custom connectors in Azure Purview, which is a unified data governance service that helps you manage and govern your on-premises, multicloud, and software-as-a-service (SaaS) data.
This application supports the following actions:
- Browse existing type definitions
- Create new enity & relationship type definitions
- Create entity templates to simplify source scanning
When combined with the Purview Custom Connector Solution Accelerator, this application provides entity templates to help create source scanning functionality. The diagram below outlines the typical journey to develop a custom connector for Azure Purview:
Prerequisites
- Azure subscription
- Azure Purview
- Localhost or Windows 365:
Deployment
This application can be deployed in various ways to meet your needs. Because the creation of type definitions is often limited to a few individuals for a limited time period, this repo is built to run locally by default.
- Local PC - default, ready for local setup below
- Windows 365 Cloud PC - securely stream Windows from the Microsoft cloud to any device
- Azure - using Static Web Apps and Functions
Local Setup
- Clone or download this repository and navigate to the project's root directory
- Follow these instructions to create an application service principal that can access the Azure Purview API
- Rename
/api/local.settings.json.rename
tolocal.settings.json
by removing.rename
extension - Edit your
/api/local.settings.json
file:- Update
AadTenantId
with your Tenant ID for Azure Active Directory - Update
AppClientId
andAppClientSecret
with your application service principal - Update
AtlasAccountName
with your Azure Purview account name - Update
StorageConnectionString
with your connection string for Azure Data Lake Storage - Update
StorageContainer
with your preferred container name
- Update
- Install the application's dependencies:
npm install
Run the App Locally
-
Start the application API from a new terminal:
cd api npm start
API now running at http://localhost:7071/api/aad/token
-
Start the application frontend from a second new terminal:
npm start
App now running at http://localhost:3000/. Note the
package.json
file has a proxy for port 7071 so you can code directly to the/api
path on localhost. For more information on the local Azure Functions, see the API README.
Deploy to Azure
-
Click the button below to create an Azure Static Web App using your GitHub repository:
-
Sign in to GitHub and authorize Azure Static Web Apps
-
Select your organization, repository, and branch from the dropdowns
-
Select
React
as the build preset -
Update the project structure:
- App location =
/
- Api location =
/api
- Output location =
build
- App location =
-
Once the resource is created, it will automatically deploy your app to a URL listed in the Azure portal.
-
Click Configuration in the left nav to add the following app settings using either the names & values previously pasted into
/api/local.settings.json
or new values for production resources.- StorageConnectionString
- AadTenantId
- AppClientId
- AppClientSecret
- AtlasAccountName
-
Click Role management in the left nav and click
Invite
- Add yourself by using AAD and your email address as it appears in AAD
- Add the
admin
role to the invite - Generate initation link and copy into a new browser window to consent
- Learn more about authentication & authorization
-
Due to the two methods of API support in Azure Static Web Apps with Azure Functions, you need to manually create an Azure Function for the
/api/AadToken
endpoint. For more information, please follow the Getting started with Azure Functions and learn how to Bring your own functions to Azure Static Web Apps.
Learn More
Azure Purview
- Purview Custom Connector Solution Accelerator
- Purview Machine Learning Lineage Solution Accelerator
- Tutorial using the REST APIs
Azure Static Web Apps
- Quickstart for React apps
- Authentication and authorization
- API support with Azure Functions
- Getting started with Azure Functions
Contributing
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.
Trademarks
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft trademarks or logos is subject to and must follow Microsoft's Trademark & Brand Guidelines. Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship. Any use of third-party trademarks or logos are subject to those third-party's policies.