You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/iot-hub/iot-hub-event-grid.md
+7-8Lines changed: 7 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -71,9 +71,9 @@ The following example shows the schema of a device connected event:
71
71
72
72
### Device telemetry schema
73
73
74
-
Device telemetry messages must be in a valid JSON format with the contentType set to **application/json** and contentEncoding set to **UTF-8** in the message [system properties](iot-hub-devguide-routing-query-syntax.md#system-properties). Both of these properties are case insensitive. If the content encoding is not set, then IoT Hub will write the messages in base 64 encoded format.
74
+
Device telemetry messages must be in a valid JSON format with the contentType set to **application/json** and contentEncoding set to **UTF-8** in the message [system properties](iot-hub-devguide-routing-query-syntax.md#system-properties). Both of these properties are case insensitive. If the content encoding is not set, then IoT Hub writes the messages in base 64 encoded format.
75
75
76
-
You can enrich device telemetry events before they are published to Event Grid by selecting the endpoint as Event Grid. For more information, see [message enrichments](iot-hub-message-enrichments-overview.md).
76
+
You can enrich device telemetry events before they're published to Event Grid by selecting the endpoint as Event Grid. For more information, see [message enrichments](iot-hub-message-enrichments-overview.md).
77
77
78
78
The following example shows the schema of a device telemetry event:
79
79
@@ -166,7 +166,7 @@ For a detailed description of each property, see [Azure Event Grid event schema
166
166
167
167
## Filter events
168
168
169
-
Event Grid enables [filtering](../event-grid/event-filtering.md) on event types, subjects, and data content. While creating the Event Grid subscription, you can choose to subscribe to selected IoT events.
169
+
Event Grid enables [filtering](../event-grid/event-filtering.md) on event types, subjects, and data content. While creating the Event Grid subscription, you can choose to subscribe to selected IoT events.
170
170
171
171
* Event type: For the list of IoT Hub event types, see [event types](#event-types).
172
172
* Subject: For IoT Hub events, the subject is the device name. The subject takes the format `devices/{deviceId}`. You can filter subjects based on **Begins With** (prefix) and **Ends With** (suffix) matches. The filter uses an `AND` operator, so events with a subject that match both the prefix and suffix are delivered to the subscriber.
@@ -180,18 +180,18 @@ The following sections describe limitations for device connected and device disc
180
180
181
181
Device connection state events are available for devices connecting using either the MQTT or AMQP protocol, or using either of these protocols over WebSockets. Requests made only with HTTPS won't trigger device connection state notifications.
182
182
183
-
* For devices connecting using Java, Node, or Python [Azure IoT SDKs](iot-hub-devguide-sdks.md) with the [MQTT protocol](iot-hub-mqtt-support.md) will have connection states sent automatically.
183
+
* For devices connecting using Java, Node, or Python [Azure IoT SDKs](iot-hub-devguide-sdks.md) with the [MQTT protocol](iot-hub-mqtt-support.md) will have connection states sent automatically.
184
184
* For devices connecting using the Java, Node, or Python [Azure IoT SDKs](iot-hub-devguide-sdks.md) with the [AMQP protocol](iot-hub-amqp-support.md), a cloud-to-device link should be created to reduce any delay in accurate connection states.
185
185
* For devices connecting using the .NET [Azure IoT SDK](iot-hub-devguide-sdks.md) with the [MQTT](iot-hub-mqtt-support.md) or [AMQP](iot-hub-amqp-support.md) protocol won’t send a device connected event until an initial device-to-cloud or cloud-to-device message is sent/received.
186
186
* Outside of the Azure IoT SDKs, in MQTT these operations equate to SUBSCRIBE or PUBLISH operations on the appropriate messaging [topics](iot-hub-mqtt-support.md). Over AMQP these equate to attaching or transferring a message on the [appropriate link paths](iot-hub-amqp-support.md).
187
187
188
188
### Device state interval
189
189
190
-
IoT Hub reports device connect and disconnect actions that occur within 60-second periods. The service attempts to report each state change event, but some may be missed. At minimum, IoT Hub reports the last known state within 60 seconds from the last state change event. This behavior may lead to behavior such as multiple device connect events reported with no device disconnect events between them.
191
-
192
-
Receiving either the same connection state event with different sequence numbers or different connection state events both mean that there was a change in the device connection state during the 60 second window.
190
+
IoT Hub attempts to report each device state change event, but some may be missed. At minimum, IoT Hub reports state change events that occur 60 seconds apart from each other. This behavior may lead to outcomes such as multiple device connect events reported with no device disconnect events between them.
193
191
192
+
<!--
194
193

194
+
-->
195
195
196
196
## Tips for consuming events
197
197
@@ -203,7 +203,6 @@ Applications that handle IoT Hub events should follow these suggested practices:
203
203
204
204
## Next steps
205
205
206
-
*[Try the IoT Hub events tutorial](../event-grid/publish-iot-hub-events-to-logic-apps.md)
207
206
*[Learn how to order device connected and disconnected events](iot-hub-how-to-order-connection-state-events.md)
208
207
*[Compare the differences between routing IoT Hub events and messages](iot-hub-event-grid-routing-comparison.md)
209
208
*[Learn more about how to use Event Grid and Azure Monitor to monitor, diagnose, and troubleshoot device connectivity to IoT Hub](iot-hub-troubleshoot-connectivity.md)
0 commit comments