Learn about the PI AF structure for MQTT Sparkplug
- Last UpdatedJan 14, 2025
- 2 minute read
As stated previously, the Sparkplug specification requires the following topic structure: namespace/group_id/message_type/node_id/[device_id] where the device_id is optional.
The connector builds an asset hierarchy using the Sparkplug topic namespace. The asset structure is as follows: group_id->node_id->device_id. For example, if a message is published to the topic spBv1.0/Edge Group/DDATA/Edge Node 1/Edge Device 1, the following PI AF structure is created:

An asset is created for each "folder", with the asset containing PI tags for that folder. For example, a metric named Edge Node 1/Edge Device 1/Analog Input 1 and published to topic spBv1.0/Complex/DDATA/Set 1/Edge Group may have an asset created like this:

If the metric property contains a property named engUnit, the connector will attempt to use that property as the PI point's unit of measure.
