You need to monitor the connection state of all devices in your IoT Hub fleet and receive an alert when a device that was previously connected goes offline unexpectedly. Which approach should you use?

Direct Answer (Verified)Reviewed by Sunny (Senior Cloud Engineer)

Correct Answer: Subscribe to IoT Hub Events via Azure Event Grid for device connected and disconnected events

IoT Hub publishes device lifecycle events (connected, disconnected, created, deleted) to Azure Event Grid in near-real-time. By subscribing to deviceDisconnected events, you can tr...

๐Ÿ“‹Part of Microsoft Certified: Azure IoT Developer Specialty (AZ-220) ยท Azure Certification Practice
Real Exam ScenarioIoT Monitoring

You need to monitor the connection state of all devices in your IoT Hub fleet and receive an alert when a device that was previously connected goes offline unexpectedly. Which approach should you use?

โœ“ Correct Answer & ExplanationIoT Monitoring

Correct Answer

Subscribe to IoT Hub Events via Azure Event Grid for device connected and disconnected events

Why This Answer Is Correct

IoT Hub publishes device lifecycle events (connected, disconnected, created, deleted) to Azure Event Grid in near-real-time. By subscribing to deviceDisconnected events, you can trigger an Azure Function or Logic App to send an alert immediately when a device drops offline โ€” without any polling.

๐Ÿ“š What This Question Tests

This question evaluates your knowledge of IoT Monitoring โ€” a core concept tested in Microsoft Certified: Azure IoT Developer Specialty (AZ-220). Understanding IoT Monitoring is essential for designing scalable, secure, and cost-effective cloud architectures. Mastery of this topic will help you answer scenario-based questions confidently on exam day.