Lookup Model¶
The Lookup Model node enables an integration flow to query models in EnOS according to the query method you configured and uses the specified data records in the output.
Node Type¶
EnOS.
Input and Output Ability¶
This node has 1 entry point and 1 exit point. Both the input and output are JSON.
Node Properties¶
Name
The name for this node.
Query Method
The method that the node uses to select the models to be used for the output. The following methods are available.
By Model Tag: Any model with model tags that matches what is returned in the expression.
By Attribute Tag: Any model with attribute tags that matches what is returned in the expression.
By Measurement Point Tag: Any model with measurement point tags that matches what is returned in the expression.
By Service Tag: Any model with event tags that matches what is returned in the expression.
By Event Tag: Any model with service tags that matches what is returned in the expression.
By Asset ID: Any model with an asset ID that matches what is returned in the expression. Only one asset ID is supported at a time.
Tag Key and Value
The tag’s key and value. Supports expression.
Output
The value of the returned models from the query, to be stored using key:value format in the output message. Currently supports model ID and model name.
Description
The description for this node.
Limitations¶
Can only query one asset ID at a time.
Samples¶
Input Sample¶
{
"externalId":"externalId",
"timestamp":24214324324,
"measurepoints":{
"speed":32,
"heat":40,
"tags":{
"color":"yellow"
}
}
}
Output Sample¶
The Lookup Model node uses the expression ${msg.measurementpoint.tags.color}
and Measurement Point Tag to search for any models whose tag matches the value of yellow
and includes the model ID in the output.
{
"externalId":"externalId",
"timestamp":24214324324,
"measurepoints":{
"speed":32,
"heat":40,
"tags":{
"color":"yellow"
}
},
"modelId":"Inverter"
}