Azure-Samples / iot-middleware-freertos-samples

This repo has samples for dev kits using the Azure IoT middleware for FreeRTOS
MIT License
77 stars 46 forks source link

[ADU] Quickly delete the deployment from the portal #217

Closed danewalton closed 1 year ago

danewalton commented 2 years ago

Scenario

An update is sent out but them immediately deleted. The device will receive the update but it won't be valid any longer. We should have some logic to try only so many times and then report the update is failed. Possibly get the twin again to make sure the twin property is still correct.

Note: there is a bug currently on service if you quickly delete the deployment where the twin property sticks around (although the Azure portal shows device on latest and no more deployment).

Thanks to @alancshi for the scenario experiment.

danewalton commented 1 year ago

Closing. The service requires you cancel the update before actually deleting it. So if connected, it will received the cancel. If it's disconnected, it will fetch the properties after reconnect and then see it was cancelled.