Search code examples
azuremqttiotazure-iot-hubazure-eventhub

Is it possible to send MQTT message to Event Hub? Or is there another way?


I am new with Azure, MQTT, and IoT. I have been given a task to create a POC on how to send MQTT message to Azure Event Hub.

And from the Event Hub processing, save the message to cloud sql server.

Is this possible? Since i read from here, that Azure Event Hub does not support MQTT. Or is there a workaround for this? Or is there a better way to do this?

Currently i am trying to research Azure Event Hub and Azure IoT hub.

Please help me. Thank you.


Solution

  • Azure Event Hub does not support MQTT, only Azure IoT Hub does. See here for details, also how to send MQTT messages with or without the Microsoft SDKS: https://learn.microsoft.com/en-us/azure/iot-hub/iot-hub-mqtt-support

    Once you send messages into IoT Hub, you can consume them on the Event Hub-compatible endpoint of the IoT Hub. Or, if you need the data in a "real" Event Hub, you can use routing to forward the messages from the IoT Hub into an Event Hub.