Routes incoming messages based on the name of the profile of the originator asset.
Preconditions
Incoming message originator entity type must be an ASSET
.
Configuration
Field descriptions
There are no available configuration fields.
JSON Schema
1
2
3
4
5
6
7
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "EmptyNodeConfiguration",
"type": "object",
"properties": {},
"additionalProperties": false
}
Message processing algorithm
- Checks whether incoming message originator entity type is an
ASSET
.- If the incoming message originator entity type is not an
ASSET
, processing end with aFailure
.
- If the incoming message originator entity type is not an
- Fetches the profile of that asset from the database to get profile name.
- If profile was not found (possible if originator no longer exist at the time of message processing), processing ends with a
Failure
.
- If profile was not found (possible if originator no longer exist at the time of message processing), processing ends with a
- Routes the incoming message to downstream nodes using connection with a label that matches exactly with fetched profile name.
Note: The incoming message is not modified.
Output connections
- Asset profile name:
- If incoming message originator entity type is an
ASSET
and profile for that asset was found.
- If incoming message originator entity type is an
Failure
:- If the incoming message originator entity type is not an
ASSET
. - If the profile for the incoming message originator was not found.
- If another unexpected error occurred during message processing.
- If the incoming message originator entity type is not an
Examples
The examples below show only the relevant fields of the incoming message. Unless explicitly stated otherwise, other message fields may have any values.
Example 1 — Originator entity type is an ASSET
with profile “Boiler Room” → routed via Boiler Room
Incoming message
Originator entity type is an ASSET
.
Node configuration
1
{}
State of the system
The asset exists and its profile name is Boiler Room
.
Result
Routed via Boiler Room
.
Explanation
The node fetches the asset’s profile and uses the exact profile name as the connection label.
Example 2 — Originator entity type is not an ASSET
→ Failure
Incoming message
Originator entity type is not an ASSET
. For example, it could be a DEVICE
or any other entity type.
Node configuration
1
{}
State of the system
Not relevant.
Result
Failure
.
Explanation
The node requires the originator entity type to be an ASSET
.
Example 3 — Asset was not found at processing time → Failure
Incoming message
Originator entity type is an ASSET
.
Node configuration
1
{}
State of the system
No asset with this ID exists (e.g., it was deleted while message was in queue).
Result
Failure
.
Explanation
The node cannot fetch the asset’s profile.
Use cases
Experienced platform users utilize asset profiles and configure specific rule chains per asset profile. This is useful to automatically route messages the platform generates: Entity Created, Entity Deleted, Attributes Updated, etc. But most of the messages are derived from the sensor data. Let’s assume we have temperature sensors in the room assets with profiles: “Freezer Room” and “Boiler Room”. We also take it that there is a relation between the room asset and the temperature device of type “Contains”. You can configure a rule chain that will change the originator of the message from the device to the related asset and route the incoming messages to the “Freezer Room” or “Boiler Room” rule chains.