The ProvisioningTransportHandler
is responsible for handling the communication between the device and the Device Provisioning Service. The three transport handlers available are ProvisioningTransportHandlerAmqp
, ProvisioningTransportHandlerHttp
, and ProvisioningTransportHandlerMqtt
. The choice of transport handler depends on the specific requirements of the scenario. For example, if the scenario requires a lightweight protocol with low overhead, MQTT may be a good choice. If the scenario requires a protocol that is more reliable and can handle larger payloads, HTTP may be a better choice. The transport handler used when creating the device client does not have to match the one used when creating the provisioning client.
References:
- What is Azure IoT Hub Device Provisioning Service?
- Tutorial: Provision devices using symmetric key enrollment groups (programming-language-nodejs)
- Quickstart: Provision an X.509 certificate simulated device (programming-language-python)