BaseTemplateInstalledReadiness

Use this node to validate whether a base template is installed in a given data space. Add this readiness check to allow users to validate template installation feasibility using the /app-framework/template/readiness API.

Asset Type Name for Rules 

Not supported

Example Definition in chain.json 

1{
2  "name": "perform_readiness_checks",
3  "label": "Performs Readiness Checks",
4  "dominoVariant": "sfdc_internal__UnifiedAnalyticsDominoVariant",
5  "parameters": {},
6  "definition": {
7    "nodes": {
8      "readiness_check": {
9        "graphNodeType": {
10          "name": "BaseTemplateInstalledReadiness"
11        },
12        "parameters": {
13          "name": "SDMCheck",
14          "dataspace": "${Variables.dataspace}",
15          "baseTemplateId": "myBaseTemplate",
16          "valueOnError": {
17            "SDMCheck": false
18          }
19        },
20        "sources": [],
21        "runAs": "CurrentUser"
22      }
23    }
24  }
25}

Parameters 

ParameterDefinition
name(Required) The name of the readiness check. The result is stored in the app context as ${Readiness.SDMCheck}.
dataspace(Required) The data space name to check for the base template installation. Usually references a variable such as ${Variables.dataspace}.
baseTemplateId(Required) The template source ID of the base template to check for.
valueOnError(Optional) A map of readiness check names to default boolean values if the check encounters an error.
condition(Optional) An EL expression, evaluated at runtime, that determines whether to run this readiness check or not.

Set runAs to CurrentUser so that this node runs with the permissions of the user installing the app. If you omit runAs, the node runs as AutoProc, a system user.

Note

App Context Values 

App Context ValueDefinition
Readiness.<name>A boolean indicating whether the base template is installed in the given data space (true) or not (false).

On Failure 

Failure handling depends on whether valueOnError is defined:

  • If no valueOnError is defined, the result is passed through as it is. A failed check returns FAIL_TERMINAL and the chain stops.
  • If valueOnError is present and the task succeeded, the result is passed through as it is.
  • If valueOnError is present and the task failed for any reason, the task returns WARN_AND_CONTINUE and passes along the error message. valueOnError is written to the app context so that downstream nodes can continue.

See Also