Recache template reference
Sample project going over how to recache a template reference, in this case a Templated Input.
Content:
- Summary
- Instructions
- Project file
Summary:
When using Template on an Input, Instance, or Flow, the pattern set that the parameters span across are "baked-in" when the related Components of that configuration are saved. If the Template Reference points to a dynamic resource, then in order to update the cached patterns for the Template parameters, one of the Components of that configuration should be resaved.
This sample project pulls data from our public OPC-UA server using a Templated Input for reading in individual tags. Test writes are made to a pipeline to trigger logic to stage new tag names, upload to the Template reference table, and then reinitialize the main pipeline that is using the Templated Input via the Project API.
Note that the Project API is typically expected to be interfaced from an external HTTP client, but this project simulates such a client within the pipeline as a demo.
Instructions:
- Import project file found at the bottom of this page.
- Enable MQTT Server on Settings page.
- The configuration expects the default port 1885. If using a different port, modify the Connector "mqtt_local" to point to the desired port.
- The project uses Project API, which is exposed on the same port as the Intelligence Hub runtime
- The configuration expects the default port 45245. If using a different port, modify the Connector "projectApi"
- Ref: https://archive.guide.highbyte.com/configuration/administration/project/project_api/
- The configuration expects the default port 45245. If using a different port, modify the Connector "projectApi"
- The Project API is interfaced with using the "projectAPI" REST Connector. The credentials used for requesting the Bearer token is the default "administrator"/"" login credentials. If this doesn't apply, then adjust the with the appropriate credentials.
- Monitor the MQTT server "mqtt_local" for activity. We'll be publishing pipeline activity here:
- Navigate to Pipeline page. It's expected for templateOpcTags to be in Error state, since the Template Reference is pointing to a SQLite table that doesn't exist yet.
- Navigate to the pipeline "updateTemplateReference_initialStageUpdateRecache. The description has information on the types of commands that can be sent to this Pipeline to activate the various logic paths:
- Type a '0' in the Test Write and Submit Write:
- You can see the templated tags start to publish from the other pipeline:
- Submit a Test Write with value '1' next... then '2', and finally '3'
Project configuration file for importing:
{
"productInfo": {
"company": "HighByte",
"product": "IntelligenceHub",
"version": "4.0.1",
"build": "2024.11.5.4",
"stage": "Release"
},
"project": {
"version": 9,
"connections": [
{
"name": "hb_opc",
"uri": "opc.tcp://52.10.6.4:49320",
"tags": [
"recacheTemplateReference"
],
"writes": {
"flattenModeledValues": false
},
"subscriptions": {
"subscriptionRate": {
"duration": 1,
"units": "Seconds"
}
},
"storeForward": {
"enabled": false,
"maxEntries": 100,
"waitOnFailureInterval": {
"duration": 1,
"units": "Seconds"
}
},
"settings": {
"security": "None",
"authentication": {
"type": "Anonymous"
},
"connectTimeoutSeconds": 5,
"requestTimeoutMS": 5000,
"maxItemsPerRead": 512,
"maxItemsPerWrite": 256,
"sessionName": ""
}
},
{
"name": "mqtt_local",
"uri": "mqtt://localhost:1885",
"tags": [
"recacheTemplateReference"
],
"writes": {
"flattenModeledValues": false
},
"subscriptions": {},
"storeForward": {
"enabled": false,
"maxEntries": 100,
"waitOnFailureInterval": {
"duration": 1,
"units": "Seconds"
}
},
"settings": {
"connectionTimeoutSeconds": 10,
"keepAliveSeconds": 60,
"requestTimeoutMS": 5000,
"cleanSession": true,
"ssl": false,
"redundantBrokers": [],
"inputDiscovery": ""
}
},
{
"name": "projectApi",
"uri": "rest.client://projectApi",
"tags": [
"recacheTemplateReference"
],
"writes": {
"flattenModeledValues": false
},
"subscriptions": {},
"storeForward": {
"enabled": false,
"maxEntries": 100,
"waitOnFailureInterval": {
"duration": 1,
"units": "Seconds"
}
},
"settings": {
"authentication": {
"type": "None",
"options": {
"grantType": "client_credentials",
"clientAuthenticationType": "body",
"loginURL": "http://0.0.0.0:45245/login",
"username": "projectApiUser",
"password": {
"type": "Encrypted",
"value": {
"keyId": "mrn0+fwGkmfxx4kisRgV/w==",
"iv": "8tX0CD4RrjmB2iS1ZsV8qg==",
"ciphertext": "4mcdx1PqmX9auH8B085f/Q=="
}
}
}
},
"baseURL": "http://0.0.0.0:45245"
}
},
{
"name": "sqliteTemplateTable",
"uri": "jdbc.sqlite://sqliteTemplateTable",
"tags": [
"recacheTemplateReference"
],
"writes": {
"flattenModeledValues": false
},
"subscriptions": {},
"storeForward": {
"enabled": false,
"maxEntries": 100,
"waitOnFailureInterval": {
"duration": 1,
"units": "Seconds"
}
},
"settings": {
"database": "templateTable.db"
}
}
],
"inputs": [
{
"name": "ProductionLine_PLC_1",
"connection": "hb_opc",
"type": "opc.tcp",
"qualifier": {
"namespaceIndex": 2,
"identifierType": "String",
"identifier": "ProductionLine.PLC_1",
"dataType": "Auto",
"type": "Branch",
"maxDepth": 1
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "ProductionLine_PLC_1_templated",
"connection": "hb_opc",
"type": "opc.tcp",
"qualifier": {
"namespaceIndex": 2,
"identifierType": "String",
"identifier": "ProductionLine.PLC_1.",
"dataType": "Auto",
"type": "Tag",
"maxDepth": 1,
"cacheInterval": {
"units": "Seconds",
"duration": 0
},
"ignoreBadQuality": false,
"browseVariableNodes": false,
"samplingInterval": {
"duration": 0,
"units": "Seconds"
},
"isComplex": true
},
"cacheLifetime": {
"enabled": false
},
"template": {
"name": "ProductionLine_PLC_1_",
"type": "Dynamic",
"reference": ""
}
},
{
"name": "login",
"connection": "projectApi",
"type": "rest.client",
"qualifier": {
"acceptType": "*/*",
"method": "POST",
"contentType": "application/json",
"includeMetadata": false,
"endpointURL": "/login",
"body": "{\"username\":\"administrator\",\"password\":\"\"}",
"isFile": false
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "partialExport_pipeline",
"connection": "projectApi",
"type": "rest.client",
"qualifier": {
"acceptType": "*/*",
"method": "POST",
"contentType": "application/json",
"includeMetadata": false,
"endpointURL": "/v1/project/partial/export",
"body": "{\n \"pipeline\": [\n {\n \"name\": \"templatedOpcTags\"\n }\n ]\n}",
"isFile": false,
"header": [
{
"name": "Authorization",
"value": ""
}
]
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "drop_stageNewTags",
"connection": "sqliteTemplateTable",
"type": "jdbc.sqlite",
"qualifier": {
"query": "DROP TABLE IF EXISTS stageNewTags",
"index": {
"enabled": false,
"indexName": "",
"indexValue": ""
}
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "drop_templateTable",
"connection": "sqliteTemplateTable",
"type": "jdbc.sqlite",
"qualifier": {
"query": "DROP TABLE IF EXISTS templateTable\n",
"index": {
"enabled": false,
"indexName": "",
"indexValue": ""
}
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "queryTemplateTableIfTagExists",
"connection": "sqliteTemplateTable",
"type": "jdbc.sqlite",
"qualifier": {
"query": "SELECT EXISTS (\nselect 1 from templateTable where tag = ''\n) as existsFlag;",
"index": {
"enabled": false,
"indexName": "",
"indexValue": ""
}
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Static",
"params": [
{
"name": "checkKey",
"pattern": "\"Motor 3.HOA\""
}
]
}
},
{
"name": "read_stageNewTags",
"connection": "sqliteTemplateTable",
"type": "jdbc.sqlite",
"qualifier": {
"query": "select * from \"stageNewTags\"",
"index": {
"enabled": false,
"indexName": "",
"indexValue": ""
}
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
},
{
"name": "read_templateTable",
"connection": "sqliteTemplateTable",
"type": "jdbc.sqlite",
"qualifier": {
"query": "select * from \"templateTable\"",
"index": {
"enabled": false,
"indexName": "",
"indexValue": ""
}
},
"cacheLifetime": {
"enabled": false
},
"template": {
"type": "Off"
}
}
],
"outputs": [],
"modeling": {
"models": [
{
"name": "opcTag",
"tags": [
"recacheTemplateReference"
],
"attributes": [
{
"attributeType": "Internal",
"name": "value",
"nullable": false,
"required": false,
"array": false,
"internalType": "Any"
},
{
"attributeType": "Internal",
"name": "_tagName",
"nullable": false,
"required": false,
"array": false,
"internalType": "Any"
},
{
"attributeType": "Internal",
"name": "_tagQuality",
"nullable": false,
"required": false,
"array": false,
"internalType": "Any"
},
{
"attributeType": "Internal",
"name": "_tagTimestamp",
"nullable": false,
"required": false,
"array": false,
"internalType": "Any"
}
]
}
],
"instances": []
},
"conditions": [],
"functions": [],
"tags": [
{
"name": "recacheTemplateReference"
}
],
"pipelines": [
{
"name": "templatedOpcTags",
"uri": "pipeline",
"tags": [
"recacheTemplateReference"
],
"settings": {
"inputStages": [
"Model"
],
"trackActivity": true,
"triggers": [
{
"name": "EventTrigger",
"config": {
"type": ".TriggerEvent",
"reference": "",
"enabled": true
},
"display": {
"position": {
"x": -450,
"y": 0
}
}
}
],
"stages": [
{
"name": "WriteNew",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"ignoreResult": false,
"qualifier": {
"topic": "",
"qos": 0,
"namedRoot": false,
"retained": false,
"breakupArrays": false
},
"connectionType": "mqtt"
},
"display": {
"position": {
"x": 690,
"y": 0
}
}
},
{
"name": "Model",
"outputs": [
"WriteNew"
],
"config": {
"type": ".ModelConfig",
"model": "opcTag",
"objectName": "",
"attributes": [
{
"name": "value",
"expression": {
"type": "JavaScript",
"expression": "return event.value.value;"
}
},
{
"name": "_tagName",
"expression": {
"type": "JavaScript",
"expression": "return event.value._tagName.split('/').pop().replace(/\\./g, '/');"
}
},
{
"name": "_tagQuality",
"expression": {
"type": "JavaScript",
"expression": "return event.value._tagQuality;"
}
},
{
"name": "_tagTimestamp",
"expression": {
"type": "JavaScript",
"expression": "return event.value._tagTimestamp;"
}
}
]
},
"display": {
"position": {
"x": 240,
"y": 0
}
}
}
]
}
},
{
"name": "updateTemplateReference_initialStageUpdateRecache",
"uri": "pipeline",
"description": "Test write the following values for the detailed modes:\n0 -\"initialLoad\" - create table with current template values.\n1 - \"checkNewTags\" - check for new tag values and write to staging table.\n2 -\"updateTemplateTable\" - move new tags from staging table to template table.\n3 -\"simulatedHttpClient\" - Recache template reference by reimporting the relevant data logic pipeline.",
"tags": [
"recacheTemplateReference"
],
"settings": {
"inputStages": [
"Transform"
],
"trackActivity": true,
"triggers": [
{
"name": "PolledTrigger",
"config": {
"type": ".TriggerPolled",
"enabled": false,
"interval": {
"duration": 1,
"units": "Days"
}
},
"display": {
"position": {
"x": -450,
"y": 0
}
}
}
],
"stages": [
{
"name": "browseTags",
"outputs": [
"elevateTagList"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "child",
"key": "Source1",
"reference": ""
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 1140,
"y": -337.5
}
}
},
{
"name": "Flatten",
"outputs": [
"convertToArray"
],
"config": {
"type": ".FlattenConfig",
"delimiter": "."
},
"display": {
"position": {
"x": 2040,
"y": -337.5
}
}
},
{
"name": "convertToArray",
"outputs": [
"switch_loadInitialOrCheckNewTags"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "let originalObject = event.value;\r\nconst convertedArray = Object.keys(originalObject).map(tag => ({\r\n tag\r\n}));\r\nstage.setValue(convertedArray);"
},
"display": {
"position": {
"x": 2490,
"y": -337.5
}
}
},
{
"name": "updateData",
"outputs": [
"initialLoad"
],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"table": "templateTable",
"writeType": "upsert",
"whereColumn": "tag=''",
"logAsJSON": false,
"createOption": "create",
"tableCacheInterval": {
"duration": 1,
"units": "Hours"
},
"breakupArrays": false,
"filterList": [
"_name",
"_timestamp"
]
},
"qualifierExpression": "",
"ignoreResult": false
},
"display": {
"position": {
"x": 4290,
"y": -472.5
}
}
},
{
"name": "replaceDummyData",
"outputs": [
"Breakup"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "event.value = [\r\n\t{\r\n\t\t\"tag\": \"Tool_1\"\r\n\t},\r\n\t{\r\n\t\t\"tag\": \"Tool_1_Count\"\r\n\t},\r\n\t{\r\n\t\t\"tag\": \"Tool_2\"\r\n\t},\r\n\t{\r\n\t\t\"tag\": \"Tool_2_Count\"\r\n\t}\r\n];\r\nstage.setValue(event.value);"
},
"display": {
"position": {
"x": 3390,
"y": -472.5
}
}
},
{
"name": "elevateTagList",
"outputs": [
"Flatten"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setValue(event.value.Source1);"
},
"display": {
"position": {
"x": 1590,
"y": -337.5
}
}
},
{
"name": "initialLoad",
"outputs": [
"getRestToken1"
],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"topic": "initialLoad/",
"qos": 0,
"namedRoot": false,
"retained": false,
"breakupArrays": false
},
"qualifierExpression": "",
"ignoreResult": false,
"connectionType": "mqtt"
},
"display": {
"position": {
"x": 4740,
"y": -472.5
}
}
},
{
"name": "Breakup",
"outputs": [
"updateData"
],
"config": {
"type": ".BreakupConfig",
"breakupType": "array"
},
"display": {
"position": {
"x": 3840,
"y": -472.5
}
}
},
{
"name": "switch_loadInitialOrCheckNewTags",
"outputs": [],
"config": {
"type": ".SwitchConfig",
"switchCases": [
{
"expression": "return Boolean(event.metadata.inputMode===\"initialLoad\") || Boolean(event.metadata.inputMode===0) ;",
"outputs": [
"replaceDummyData"
],
"description": "Initial loading of template table"
},
{
"expression": "return Boolean(event.metadata.inputMode===\"checkNewTags\") || Boolean(event.metadata.inputMode===1) || Boolean(JSON.stringify(event.metadata.inputMode)==='{}');",
"outputs": [
"Breakup_1"
],
"description": "Polled monitoring of new tags"
},
{
"expression": "return Boolean(event.metadata.inputMode===\"updateTable\") || Boolean(event.metadata.inputMode===2) ;",
"outputs": [],
"description": "Move new tags from stageNewTable to templateTable"
},
{
"expression": "return true;",
"outputs": [
"catchDefaultswitch_loadInitialOrCheckNewTags"
],
"description": "default"
}
],
"evaluationType": "onFirst"
},
"display": {
"position": {
"x": 2940,
"y": -337.5
}
}
},
{
"name": "Transform",
"outputs": [
"switch_browseNamespaceOrLoadStagedTags"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setMetadata(\"inputMode\",event.value);"
},
"display": {
"position": {
"x": 240,
"y": 0
}
}
},
{
"name": "Read",
"outputs": [
"Filter"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "child",
"key": "checkTagExists",
"reference": ")}}"
}
],
"inputValueLocation": "inline",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 3840,
"y": -270
}
}
},
{
"name": "Breakup_1",
"outputs": [
"Read"
],
"config": {
"type": ".BreakupConfig",
"breakupType": "array"
},
"display": {
"position": {
"x": 3390,
"y": -270
}
}
},
{
"name": "mqtt_stageNewTags",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"qos": 0,
"namedRoot": false,
"retained": false,
"topic": "stageNewTags/",
"breakupArrays": false
},
"qualifierExpression": "",
"ignoreResult": false
},
"display": {
"position": {
"x": 5190,
"y": -67.5
}
}
},
{
"name": "sqlite_stageNewTags",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"table": "stageNewTags",
"writeType": "upsert",
"whereColumn": "tag=''",
"logAsJSON": false,
"createOption": "create",
"tableCacheInterval": {
"duration": 1,
"units": "Hours"
},
"breakupArrays": false,
"filterList": [
"_timestamp",
"_name"
]
},
"qualifierExpression": "",
"ignoreResult": false,
"connectionType": "jdbc.sqlite"
},
"display": {
"position": {
"x": 5190,
"y": -202.5
}
}
},
{
"name": "Switch_1",
"outputs": [],
"config": {
"type": ".SwitchConfig",
"switchCases": [
{
"expression": "return Boolean(event.metadata.filtered.checkTagExists[0].existsFlag===1)",
"outputs": [
"mqtt_existingTags"
],
"description": "Tag exists"
},
{
"expression": "return Boolean(event.metadata.filtered.checkTagExists[0].existsFlag===0)",
"outputs": [
"sqlite_stageNewTags",
"mqtt_stageNewTags"
],
"description": "New tag"
},
{
"expression": "return true",
"outputs": [],
"description": "default"
}
],
"evaluationType": "onFirst"
},
"display": {
"position": {
"x": 4740,
"y": -270
}
}
},
{
"name": "mqtt_existingTags",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"topic": "existingTags/",
"qos": 0,
"namedRoot": false,
"retained": false,
"breakupArrays": false
},
"qualifierExpression": "",
"ignoreResult": false
},
"display": {
"position": {
"x": 5190,
"y": -337.5
}
}
},
{
"name": "Filter",
"outputs": [
"Switch_1"
],
"config": {
"type": ".AttributeFilterConfig",
"filterOption": "include",
"attributeList": [
"tag"
],
"retainAsMetadata": true,
"metadataKey": "filtered"
},
"display": {
"position": {
"x": 4290,
"y": -270
}
}
},
{
"name": "catchDefaultswitch_loadInitialOrCheckNewTags",
"outputs": [],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setValue(event.value);"
},
"display": {
"position": {
"x": 3390,
"y": -135
}
}
},
{
"name": "switch_browseNamespaceOrLoadStagedTags",
"outputs": [],
"config": {
"type": ".SwitchConfig",
"switchCases": [
{
"expression": "return Boolean(event.metadata.inputMode===\"initialLoad\") || Boolean(event.metadata.inputMode===0) || Boolean(event.metadata.inputMode===\"checkNewTags\") || Boolean(event.metadata.inputMode===1) || Boolean(JSON.stringify(event.metadata.inputMode)==='{}');",
"outputs": [
"browseTags"
],
"description": "Scan namespace"
},
{
"expression": "return Boolean(event.metadata.inputMode===\"updateTemplateTable\") || Boolean(event.metadata.inputMode===2) ;",
"outputs": [
"getStagedTags"
],
"description": "Move stageNewTags to templateTable"
},
{
"expression": "return Boolean(event.metadata.inputMode===\"simulatedHttpClient\") || Boolean(event.metadata.inputMode===3) ;",
"outputs": [
"getRestToken"
],
"description": "Recache template reference"
},
{
"expression": "return true;",
"outputs": [
"catchDefaultSwitch_browseNamespaceOrLoadStagedTags"
],
"description": "default"
}
],
"evaluationType": "onFirst"
},
"display": {
"position": {
"x": 690,
"y": 0
}
}
},
{
"name": "getStagedTags",
"outputs": [
"elevate_stagedTags"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "child",
"key": "stagedTags",
"reference": ""
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 1140,
"y": -202.5
}
}
},
{
"name": "WriteNew",
"outputs": [
"Breakup_2"
],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"table": "templateTable",
"writeType": "upsert",
"whereColumn": "tag=''",
"logAsJSON": false,
"createOption": "off",
"tableCacheInterval": {
"duration": 1,
"units": "Hours"
},
"breakupArrays": false
},
"qualifierExpression": "",
"ignoreResult": false
},
"display": {
"position": {
"x": 2040,
"y": -202.5
}
}
},
{
"name": "mqtt_uploadedTags",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"topic": "uploadedTags/",
"qos": 0,
"namedRoot": false,
"retained": false,
"breakupArrays": false
},
"qualifierExpression": "",
"ignoreResult": false
},
"display": {
"position": {
"x": 2940,
"y": -202.5
}
}
},
{
"name": "Breakup_2",
"outputs": [
"mqtt_uploadedTags"
],
"config": {
"type": ".BreakupConfig",
"breakupType": "array"
},
"display": {
"position": {
"x": 2490,
"y": -202.5
}
}
},
{
"name": "elevate_stagedTags",
"outputs": [
"WriteNew"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setValue(event.value.stagedTags);"
},
"display": {
"position": {
"x": 1590,
"y": -202.5
}
}
},
{
"name": "catchDefaultSwitch_browseNamespaceOrLoadStagedTags",
"outputs": [],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setValue(event.value);"
},
"display": {
"position": {
"x": 1140,
"y": 67.5
}
}
},
{
"name": "getPipelineExport",
"outputs": [
"restPIpelineImport"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "inline",
"key": "Source1",
"reference": ""
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 2040,
"y": -67.5
}
}
},
{
"name": "restPIpelineImport",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"qualifier": {
"endpointURL": "/v1/project/partial/import",
"method": "POST",
"bodyType": "defaultjson",
"breakupArrays": false,
"filterList": [
"_timestamp"
],
"header": [
{
"value": "",
"name": "Authorization"
}
]
},
"qualifierExpression": "",
"ignoreResult": false,
"connectionType": "rest.client"
},
"display": {
"position": {
"x": 2490,
"y": -67.5
}
}
},
{
"name": "getRestToken",
"outputs": [
"putRestTokenInMetadata"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "inline",
"key": "Source1",
"reference": ""
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 1140,
"y": -67.5
}
}
},
{
"name": "putRestTokenInMetadata",
"outputs": [
"getPipelineExport"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setMetadata(\"restToken\",event.value.token)"
},
"display": {
"position": {
"x": 1590,
"y": -67.5
}
}
},
{
"name": "getPipelineExport1",
"outputs": [
"restPipelineImport1"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "inline",
"reference": "",
"key": "Source1"
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 6090,
"y": -472.5
}
}
},
{
"name": "restPipelineImport1",
"outputs": [],
"config": {
"type": ".DynamicWriteConfig",
"failureOutputs": [],
"connectionReference": "",
"ignoreResult": false,
"qualifier": {
"endpointURL": "/v1/project/partial/import",
"method": "POST",
"bodyType": "defaultjson",
"breakupArrays": false,
"header": [
{
"name": "Authorization",
"value": ""
}
]
},
"connectionType": "rest.client"
},
"display": {
"position": {
"x": 6540,
"y": -475.0357837320559
}
}
},
{
"name": "getRestToken1",
"outputs": [
"putRestTokenInMetadata1"
],
"config": {
"type": ".ReadSourcesConfig",
"keyReferences": [
{
"location": "inline",
"reference": "",
"key": "Source1"
}
],
"inputValueLocation": "exclude",
"inputValueKey": "eventIn"
},
"display": {
"position": {
"x": 5190,
"y": -472.5
}
}
},
{
"name": "putRestTokenInMetadata1",
"outputs": [
"getPipelineExport1"
],
"config": {
"type": ".TransformConfig",
"transformExpression": "stage.setMetadata(\"restToken\",event.value.token)"
},
"display": {
"position": {
"x": 5640,
"y": -472.5
}
}
}
]
}
}
],
"namespace": []
},
"network": {
"groups": [],
"hubs": []
}
}