0

I am currently trying to send messages to the Azure IoT Hub using MQTT and the C library. When sending a message via IoTHubDeviceClient_SendEventAsync shortly after the network connection is lost, it takes several minutes until the callback is called.

Is there any way to shorten this time to get faster response if the connection is lost?

koalo
  • 2,113
  • 20
  • 31

1 Answers1

0

You can set "timeout" and "messageTimeout" with IoTHubClient_SetOption(). Maybe setting the retry policy with IoTHubClient_SetRetryPolicy() is also helpful for you.

René
  • 3,413
  • 2
  • 20
  • 34
  • According to https://github.com/Azure/azure-iot-sdk-c/blob/master/iothub_client/inc/iothub_client_options.h messageTimeout is deprecated – koalo May 17 '19 at 13:20