Table of Contents

Class OutgoingTelemetryMetadata

Namespace
Azure.Iot.Operations.Protocol.Telemetry
Assembly
Azure.Iot.Operations.Protocol.dll

The metadata that can be sent with every publish packet sent by a TelemetrySender<T>.

public class OutgoingTelemetryMetadata
Inheritance
OutgoingTelemetryMetadata
Inherited Members

Constructors

OutgoingTelemetryMetadata()

Construct an instance with the default values.

public OutgoingTelemetryMetadata()

Remarks

  • The CorrelationData field will be set to a new, random GUID.
  • The Timestamp field will be set to the current HybridLogicalClock time for the process.
  • The UserData field will be initialized with an empty dictionary; entries in this dictionary can be set by user code as desired.

Properties

CloudEvent

public CloudEvent? CloudEvent { get; set; }

Property Value

CloudEvent

PersistTelemetry

If true, this telemetry will be persisted by the AIO MQTT broker upon receiving it. This is only applicable for retained messages. If this value is set to true, Retain must also be set to true.

public bool PersistTelemetry { get; set; }

Property Value

bool

Remarks

This feature is only applicable with the AIO MQTT broker.

Retain

If true, this MQTT message will be retained by the MQTT broker.

public bool Retain { get; set; }

Property Value

bool

Timestamp

A mandatory timestamp attached to the telemetry message.

public HybridLogicalClock? Timestamp { get; }

Property Value

HybridLogicalClock

Remarks

A message sent by a TelemetrySender<T> will include a non-null timestamp. A message sent by anything else may or may not include this timestamp.

UserData

A dictionary of user properties that are sent along with the telemetry message from the TelemetrySender.

public Dictionary<string, string> UserData { get; }

Property Value

Dictionary<string, string>