Errata exists for this version of the document.

Each JSON NetworkMessage contains one or more JSON DataSetMessages. The JSON NetworkMessage is a JSON object with the fields defined in Table 91.

Table 91 – JSON NetworkMessage Definition

Name

Type

Description

MessageId

String

A globally unique identifier for the message.

This value is mandatory.

MessageType

String

This value shall be “ua-data”.

This value is mandatory.

PublisherId

String

A unique identifier for the Publisher. It identifies the source of the message.

This value is optional. The presence of the value depends on the setting in the JsonNetworkMessageContentMask.

The source is the PublisherId on a PubSubConnection (see 6.2.6.1).

DataSetClassId

String

The DataSetClassId associated with the DataSets in the NetworkMessage.

This value is optional. The presence of the value depends on the setting in the JsonNetworkMessageContentMask.

If specified, all DataSetMessages in the NetworkMessage shall have the same DataSetClassId.

The source is the DataSetClassId on the PublishedDataSet (see 6.2.2.2) associated with the DataSetWriters that produced the DataSetMessages.

Messages

*

A JSON array of JSON DataSetMessages (see 7.2.3.3).

This value is mandatory.

All fields with a concrete DataType defined are encoded using reversible OPC UA JSON Data Encoding defined in OPC 10000-6.

The fields in the JSON NetworkMessage are controlled by the NetworkMessageContentMask of the JSON NetworkMessage mapping(see 6.3.2.1.1).

If the NetworkMessageHeader bit of the NetworkMessageContentMask is not set, the NetworkMessage is the contents of the Messages field (e.g. a JSON array of DataSetMessages).

If the DataSetMessageHeader bit of the NetworkMessageContentMask is not set, the content of the Messages field is an array of content from the Payload field for each DataSetMessage (see 7.2.3.3).

If the SingleDataSetMessage bit of the NetworkMessageContentMask is set, the content of the Messages field is a JSON object containing a single DataSetMessage.

If the NetworkMessageHeader and the DataSetMessageHeader bits are not set and SingleDataSetMessage bit is set, the NetworkMessage is a JSON object containing the set of name/value pairs defined for a single DataSet.

If the JSON encoded NetworkMessage size exceeds the Broker limits the message is dropped and a PubSubTransportLimitsExceeded Event is reported.