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
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.
  1. On the FactoryTalk DataMosaix Management Console, select the
    Extractor Info
    tab.
  2. Click the [Add] icon.
  3. On the Extractor Info Detail screen, provide a unique and meaningful name for the extractor.
  4. In the Pipeline field, provide the extraction pipeline name created earlier.
  5. Select the Source Type as Add Custom / Other.
  6. Click [Save and Create Credentials] to register the extractor.
  7. 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.
Upload Data to CDF project
Before you begin with creating transformation, ensure you have uploaded the data to the CDF project either manually or using the CLI toolkit in the staging area. For information on uploading data, refer to the CDF documentation.
Create Transformation
After you have uploaded the data to the CDF project, you need to create a transformation in CDF.
  1. Navigate to your project in CDF and select
    Integrate > Transform Data
    .
  2. On the Transform Data screen, click [+ Create].
  3. Provide a unique name for the transformation.
  4. Provide a unique external ID.
  5. Select a data set to limit access to the selected data set and click [Next Step].
  6. In the [Target data model] list, select
    CDF resource types
    to 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.
  7. In the [Target resource type] list, select
    Assets
    .
  8. In the [Action] list, select
    Create or Update
    .  If you're updating existing data, you must specify how the transformation should set null values.
    • Select
      Keep existing values
      to not update existing data. This is the default setting.
    • Select
      Clear existing values
      to 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.
  9. Click [Create] to create the transformation. After you create a transformation, you need to select a source for data transformation.
    The Mapping editor displays. Mapping editor helps mapping source and target.
  10. In the
    Mapping editor
    , select the source for transformation. Select the appropriate model, database name, and the table name.
  11. To map your source data and target, click [Suggestions] and select all that apply.
  12. After you select the suggestions, click [Accept Selected]. You can see the mappings.
    Now you are ready to run the transformation.
Set Client Credentials for Transformation
  1. In the Mapping editor, click [Run} and select [Run with client credentials].
    If the client credentials are not set, you shall see the missing credentials dialog box. You need to set your client credentials before you can run a transformation.
  2. Click [Set client credentials].
  3. On the Client Credentials dialog 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
  1. In the Mapping editor, click [Run} and select [Run with client credentials].
    You should now see the label [configured], when you select [Run with client credentials].
  2. Click [Run with client credentials].
  3. You can view the transformation data under Run History.
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.