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¶
Logic.
Input and Output Ability¶
This node has 1 entry point and 1 exit point. Both the input and output are JSON.
Node Properties¶
Node Name
Required.
The name for this node.
Query Method
Required.
The method that the node uses to select the models to be used for the output. The following methods are available.
Model Tag: Any model with model tags that matches what is returned in the expression.
Attribute Tag: Any model with attribute tags that matches what is returned in the expression.
Measurement Point Tag: Any model with measurement point tags that matches what is returned in the expression.
Service Tag: Any model with event tags that matches what is returned in the expression.
Event Tag: Any model with service tags that matches what is returned in the expression.
Tag Key and Value
Required.
The tag’s key and value. Supports expression.
Output
Required.
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
Optional.
The description for this node.
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"
}