Azure Data Explorer IoT Hub Connection: IoT Hub System Properties only mapped to a single ingested message in a MULTIJSON message

Osman 1 Reputation point
2022-10-28T06:49:26.557+00:00

Hi, good morning.
I have developed a IoT Edge solution that allows sending messages in batches to IoT Hub. Instead of sending single json messges, I'm sending a Json array in order to reduce sending IoT Hub message number due to costs. All is working fine, and messages are arriving correctly in the IoT Hub.

But when I try to ingest these messages directly in Azure Data Explorer using IoT Hub Data Connection, I've a problem mapping Event System Properties to the messages.
As I'm using MULTIJSON format, each single message in the array is processed correctly, but the Event System Properties, for example the DeviceId, are only being mapped to a single message in the batch.

Is there a way to map these properties to all messages in the json array before storing them in ADX table.

Thank you very much.
Best regards.

255013-ingesteddata.jpg

Azure IoT Edge
Azure IoT Edge
An Azure service that is used to deploy cloud workloads to run on internet of things (IoT) edge devices via standard containers.
535 questions
Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
1,116 questions
Azure Data Explorer
Azure Data Explorer
An Azure data analytics service for real-time analysis on large volumes of data streaming from sources including applications, websites, and internet of things devices.
480 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Wilko van de Velde 2,226 Reputation points
    2022-11-01T06:58:01.713+00:00

    Hi,

    I don's see anything strange to your mapping. I don't know if it will work but the next thing I would try is mapping the data to a source table (maybe even with JSON format instead of the MULTIJSON) and then use update policies to resolve the data. My friend @Sander van de Velde wrote a blog about it:

    https://sandervandevelde.wordpress.com/2022/07/29/using-adx-table-update-policies-projecting-raw-messages-to-target-tables/

    1 person found this answer helpful.
    0 comments No comments