Skip to main content
Skip table of contents

CONFIG_LOAD_TEMPLATES

CONFIG_LOAD_TEMPLATES is a configuration package that is used to create reusable Load templates, which can be used directly from Designer user interface.


See also:


Usage

Saving a load as a load template

  1. Open any Package from Designer package list

  2. Open any Entity from Package

  3. Open Loads and choose an existing load or create a new one

  4. In Loads view, you can choose save as template option:

  5. Save as a template window opens up, where you need to specify template name and description

  6. New load template is created and it can be found from CONFIG_LOAD_TEMPLATES package

All characteristics of current Load are saved to Template, such as load steps, including all the SQL code and load options. See examples section for more information.

Note that after saving a load template, CONFIG_LOAD_TEMPLATES package will have uncommitted changes. To maintain version history for CONFIG_LOAD_TEMPLATES, commit the package after making changes.


Overwriting or updating a load template

Follow the same steps as when creating a new load template, but save the template with the same name as an existing load template. You will be prompted if you wish to override the template.

Alternatively, you can also edit the package JSON manually (see below).


Editing package JSON

  1. Open the configuration package from Designer package list.

  2. Click Export package in the Actions tab.

  3. Click Download.

  4. Edit JSON file.

  5. Import edited JSON back to Designer with Import Package.

After a successful import, changes to the configuration package have been applied to Designer only. It is recommended to deploy the same changes to Runtime environments as well.


Contents

Entity load logic template configuration

Entity load logic template configurations are managed inside the JSON array block named, entityLoadLogicTemplates.

Key

Value type

Example

Description

entityLoadLogicTemplateId

String

dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6

The unique identifier of the entity load logic template. Can be generated with online tools, such as UUID Generator.

templateName

String

DUPLICATES_SMOKE_BLACK

The name of the entity load logic template.

templateDescription

String

Template for Smoke Black Optional. The description of the entity load logic template.

You can add a new entity load logic template or update the contents of an existing entity load logic template.

Example: Entity Load logic template configuration

JSON
"entityLoadLogicTemplates": [
  . . .
  {
    "entityLoadLogicTemplateId": "dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6",
    "templateName": "DUPLICATES_SMOKE_BLACK",
    "templateDescription": null
  }
  . . .
]

Entity load logic template load step configuration

Entity load logic template load step configurations are managed inside the JSON array block named, entityLoadLogicTemplateLoadSteps.

You can use Runtime variables for Load templates in order to create dynamic Load steps.

Key

Value type

Example

Description

entityLoadLogicTemplateLoadStepId

String

47e26041-dfc3-4ddb-a6cb-77ca014b823f

The unique identifier of the entity load logic template load step. Can be generated with online tools, such as UUID Generator.

entityLoadLogicTemplateId

String

dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6

The unique identifier of the entity load logic template. For more information, refer to the Entity Load Logic Template Configuration section above.

loadStepName

String

duplicates_smoke_black

The name of the load step.

position

Integer

1

The position of the load step.

stepType

String

SMOKE_BLACK

The type of the load step. For more information, refer to the Load Step Type Configuration section.

loadLanguageName

String

SQL

The load language of the load step. For more information, refer to the Load Language Configuration section.

textStep

String

SELECT COUNT(*) FROM <target_schema>.<target_entity_name>

The logic of the load step. It is possible to use Runtime variables for specifying schema and entity names dynamically.

readAffectedRows

Boolean

false

Whether affected rows are read or not.

You can add a new entity load logic template load step or update the contents of an existing entity load logic template load step.

Example: Entity Load logic template Load step configuration

JSON
"entityLoadLogicTemplateLoadSteps": [
  . . .
  {
    "entityLoadLogicTemplateLoadStepId": "47e26041-dfc3-4ddb-a6cb-77ca014b823f",
    "entityLoadLogicTemplateId": "dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6",
    "loadStepName": "duplicates_smoke_black",
    "position": 1,
    "stepType": "SMOKE_BLACK",
    "loadLanguageName": "SQL",
    "textStep": "SELECT COUNT(*) FROM <target_schema>.<target_entity_name>",
    "readAffectedRows": false,
  }
  . . .
]

Entity Load Logic Template Load Opt Configuration

Entity load logic template load opt configurations are managed inside the JSON array block named, entityLoadLogicTemplateLoadOpts.

Key

Value type

Example

Description

entityLoadLogicTemplateLoadOptId

String

4bc00e7a-a2b2-4b44-a32f-35cfb33e66c3

The unique identifier of the entity load logic template load option. Can be generated with online tools, such as UUID Generator.

entityLoadLogicTemplateId

String

dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6

The unique identifier of the entity load logic template. For more information, refer to the Entity Load Logic Template Configuration section above.

loadOptName

String

OPT_USE_RUN_IDS

The name of the load option.

value

String

true

The value of the load option.

loadOptType

String

OPT_USE_RUN_IDS

The type of the load option.

You can add a new entity load logic template load opt or update the contents of an existing entity load logic template load opt.

Example: Entity Load Logic Template Load Opt Configuration

JSON
"entityLoadLogicTemplateLoadOpts": [
  . . .
  {
    "entityLoadLogicTemplateLoadOptId": "4bc00e7a-a2b2-4b44-a32f-35cfb33e66c3",
    "entityLoadLogicTemplateId": "dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6",
    "loadOptName": "OPT_USE_RUN_IDS",
    "value": "true",
    "loadOptType": "OPT_USE_RUN_IDS"
  }
  . . .
]

If an existing entity load logic template load opt needs to be deleted, simply remove it from the set of values before importing the configuration package.


Entity Type Entity Load Type Entity Load Logic Template Configuration

Entity type entity load type entity load logic template configurations are managed inside the JSON array block named, entityTypeEntityLoadTypeEntityLoadLogicTemplates.

Key

Value type

Example

Description

entityTypeEntityLoadTypeEntityLoadLogicTemplateId

String

be64ab95-6980-48d3-b049-2a8ee806b5d7

The unique identifier of the Entity type entity load type entity load logic template. Can be generated with online tools, such as UUID Generator.

entityLoadLogicTemplateId

String

dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6

The unique identifier of the entity load logic template. For more information, refer to the Entity Load Logic Template Configuration section above.

entityType

String

HUB

The type of the entity.

entityLoadType

String

TRANSFORM_PERSIST

The type of the entity load.

templateOrdinalPosition

Integer

1000

The ordinal position of the template.

isDefault

Boolean

false

Whether the template is enabled by default or not. If the template is set to be enabled by default, it will be automatically applied to newly created entity load based on the Entity Type and Entity Load Type.

You can add a new Entity type entity load type entity load logic template or update the contents of an existing Entity type entity load type entity load logic template.

Example: Entity Type Entity Load Type Entity Load Logic Template Configuration

JSON
"entityTypeEntityLoadTypeEntityLoadLogicTemplates": [
  . . .
  {
    "entityTypeEntityLoadTypeEntityLoadLogicTemplateId": "be64ab95-6980-48d3-b049-2a8ee806b5d7",
    "entityType": "HUB",
    "entityLoadType": "TRANSFORM_PERSIST",
    "entityLoadLogicTemplateId": "dcb95551-8b4e-4ac1-86a9-ae33bffd9dc6",
    "templateOrdinalPosition": 1000,
    "isDefault": false
  }
  . . .
]

If an existing Entity type entity load type entity load logic template needs to be deleted, simply remove it from the set of values before importing the configuration package.


Examples

Creating a new Load Template from existing Load

In Entity Loads, we have specified a Load Step with type SMOKE_GREY. In addition, we have Load options OPT_USE_RUN_IDS selected:

Now when selecting save as a template, a new window opens up with the possibility to define Template name, description and other options:

After saving the template, we can check out CONFIG_LOAD_TEMPLATES package with the following JSON:

JSON
  "entityLoadLogicTemplates": [
    {
      "entityLoadLogicTemplateId": "2661f7c5-901f-4057-9723-ef0cdc979b3e",
      "templateName": "DUPLICATES_SMOKE_GREY_WITH_RUNID",
      "templateDescription": "Detects duplicate values in DV entities."
    }
  ],
  "entityLoadLogicTemplateLoadSteps": [
    {
      "entityLoadLogicTemplateLoadStepId": "db852992-b29a-4d8d-b44f-751c58c44846",
      "entityLoadLogicTemplateId": "2661f7c5-901f-4057-9723-ef0cdc979b3e",
      "loadStepName": "duplicates_smoke_grey",
      "position": 1,
      "stepType": "SMOKE_GREY",
      "loadLanguageName": "SQL",
      "textStep": "-- Duplicates Smoke Test based on the newly loaded rows\\nSELECT \\n           COUNT(*) AS has_duplicates\\nFROM (\\n           SELECT\\n                       DV_ID, \\n                       COUNT(1) AS cnt_rows\\n           FROM\\n                       <target_schema>.<target_entity_name>\\n           WHERE\\n                       DV_ID IN (SELECT DV_ID FROM <target_schema>.<target_entity_name> WHERE dv_run_id IN (<targetbatchid>))\\n           GROUP BY\\n                       DV_ID\\n           HAVING\\n                       COUNT(1) > 1\\n) t1\\nHAVING\\n           COUNT(*) > 0",
      "readAffectedRows": false
    }
  ],
  "entityLoadLogicTemplateLoadOpts": [
    {
      "entityLoadLogicTemplateLoadOptId": "9cb351b5-e253-4391-87e7-9f2c12a0efdd",
      "entityLoadLogicTemplateId": "2661f7c5-901f-4057-9723-ef0cdc979b3e",
      "loadOptName": "OPT_USE_RUN_IDS",
      "value": "true",
      "loadOptType": "OPT_USE_RUN_IDS"
    }
  ],
  "entityTypeEntityLoadTypeEntityLoadLogicTemplates": [
    {
      "entityTypeEntityLoadTypeEntityLoadLogicTemplateId": "62e058d3-6d0d-48fb-9048-fa47de728632",
      "entityType": "HUB",
      "entityLoadType": "TRANSFORM_PERSIST",
      "entityLoadLogicTemplateId": "2661f7c5-901f-4057-9723-ef0cdc979b3e",
      "templateOrdinalPosition": 1000,
      "isDefault": false
    }
  ]

Load Template can now be used in Loads with Add from template:

And choosing one of the options from templates:

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.