Setup Data Transformation for CDF
This topic describes the steps to set up and run data transformation where Auth0 is used as Identity Provider (IdP). A user must perform the steps in both, FactoryTalk Data Mosaix and Cognite Data Fusion (CDF). CDF, when using Auth0 as the IdP, requires client credentials in order to run data transformations.
Prerequisites
- A CDF project exists.
- You have appropriate read, write access to the project to upload data. For information on access you need, refer to Set up the CDF project and get credentials.
Register an Extractor
To run data transformation using Auth0 as the IdP, CDF requires client credentials (M2M Token). To get the appropriate client credentials, you must first register an extractor and save the client ID and secret generated.
- On the FactoryTalk DataMosaix Management Console, select theExtractor Infotab.
- Click the Add [+] icon.
- On the Extractor Info Detail page, provide a unique and meaningful name for the extractor.
- In the Pipeline field, provide the extraction pipeline name created earlier.
- Select theSource Typeas Add Custom / Other.
- ClickSave and Applyto register the extractor. Credentials and other information are displayed.
- Copy and save the client secret information. You will need to use this information while setting credentials to run data transformation.
Setup Data Transformation on CDF
After you have registered the extractor and stored the client credentials, you can get started with data transformation.
Create Transformation
After you have uploaded the data to the CDF project, you need to create a transformation in CDF.
- Navigate to your project in CDF and selectIntegrate>Transform Data.
- On the Transform Data screen, click+ Create.
- Provide a unique name for the transformation.
- Provide a unique external ID.
- Select a data set to limit access to the selected data set and clickNext Step.
- In theTarget data modellist, selectCDF resource typesto ingest data.
- If you're ingesting data into the Assets resource type, make sure a parent asset already exists in CDF.
- If you're ingesting data into Sequence rows, specify the external ID for the sequence you want to write to. This defines the target schema.
- In theTarget resource typelist, selectAssets.
- In theActionlist, selectCreate or Update. If you're updating existing data, you must specify how the transformation should set null values.
- SelectKeep existing valuesto not update existing data. This is the default setting.
- SelectClear existing valuesto set existing values to null, for example, when a piece of equipment is removed for maintenance. Use this option to disassociate the asset from its parent in the asset hierarchy.
- ClickCreateto create the transformation. After you create a transformation, you need to select a source for data transformation.The Mapping editor is displayed. Mapping editor helps mapping source and target.
- In theMapping editor, select the source for transformation. Select the appropriate model, database name, and the table name.
- To map your source data and target, clickSuggestionsand select all that apply.
- After you select the suggestions, clickAccept Selected. You can see the mappings.Now you are ready to run the transformation.
Set Client Credentials for Transformation
- In the Mapping editor, clickRunand selectRun with client credentials.If the client credentials are not set, you can see the missing credentials dialog box. You need to set your client credentials before you can run a transformation.
- ClickSet client credentials.
- On theClient Credentialsdialog box, provide the client credentials that you saved when you registered an extractor earlier.Now you are ready to run the transformation.
Run Data Transformation
- In the Mapping editor, clickRunand selectRun with client credentials.You should now see the labelconfigured, when you selectRun with client credentials.
- ClickRun with client credentials.
- You can view the transformation data under Run History.
Provide Feedback