feat(mqtt): Sparkplug DataSet / Template / PropertySet metric support
#515
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
SparkplugCodechandles scalar metrics.DataSet,Template(UDT instances) andPropertySetmetrics areskipped with a warning — v1-unsupported by explicit decision, recorded in the plan's Deferred / out of
scope section and design §3.5. This issue tracks closing that.
The current behaviour is the right default and should survive any fix: an unsupported metric is skipped and
warned about, never coerced into a guessed type. A
Templateflattened into a String, or aDataSetwhosefirst column is silently taken as "the value", would bind a tag to data that is not what its name says — worse
than not binding it. Whatever shape support takes, do not lose the skip-and-warn fallback for the cases it
still does not cover.
Design questions to settle first, since these are structured values and OPC UA has more than one honest
mapping:
Template— map to an OPC UA Structure/UDT, or flatten members into sibling tags (Motor/Speed,Motor/Torque)? Flattening interacts with #509: member paths contain/.DataSet— a table has no single scalar value. Array-valued variable, or per-column tags?PropertySet— arguably not a value at all; likely belongs on the node as OPC UA properties/metadatarather than as tags.
Bytes/Filemetrics beyond a base64/raw-String fallback are the same class of gap and can ride along or splitout.
Acceptance. A simulator publishing a
Templateand aDataSetmetric produces addressable, correctly-typedOPC UA nodes, live-verified; every still-unsupported kind continues to skip with a warning.