question

OMEPIoTDeveloper-9052 avatar image
0 Votes"
OMEPIoTDeveloper-9052 asked SandervandeVelde42 commented

Where is my sensor data being stored in the IoT Hub?

Context: I am sending temp/humidity data from a sensor, through a gateway device to azure which is supposedly being stored in the IoT Hub.

Problem: Where is this data? I can access it through the device twin & also see it being sent via the Azure CLI, but the data logged in the IoT Hub only conveys information about the gateway message itself, not the actual data.

Can this information only be accessed via another service?


Looking for clarification, tips/tricks. Thanks!

azure-iot-hubazure-iot
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

SandervandeVelde42 avatar image
1 Vote"
SandervandeVelde42 answered SandervandeVelde42 commented

@OMEPIoTDeveloper-9052 ,

as seen in the documentation, "IoT Hub is a managed service, hosted in the cloud, that acts as a central message hub for bi-directional communication between your IoT application and the devices it manages.".

It's a message hub that outputs incoming messages to other Azure resources which are subscribed to certain messages.

The IoT Hub can support eg. Azure Storage, Azure Stream Analytics, or Azure Functions.

Azure Storage is great for cool or cold storage, just put all raw data over there for later analysis by a data scientist.

So yes, you need to pick up the messages yourself and put them into a SqlAzure database or show it in Power BI or run a global Website that uses Cosmos DB data that you routed into there.

Under the hood, there is some kind of storage, but only as internal, temporary storage until messages are picked up (incoming messages have a Time-To-Live for up to 7 days).

I recommend the MS Learn Introduction to Azure IoT learning path which looks into this more closely.

· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@SandervandeVelde42 So to clarify, there is no way to view device data in the iot hub itself? Thanks

0 Votes 0 ·
SandervandeVelde42 avatar image SandervandeVelde42 OMEPIoTDeveloper-9052 ·

Hello @OMEPIoTDeveloper-9052 ,

If other services are set as consumers using the route, there just are no messages kept in the IoT Hub. Everything is just send away :-)

You can check incoming messages using a tool like the Azure IoT Explorer.

If you want to have historian-like insights on your IoT Hub, I recommend checking out TimeSeries Insights which is capable of showing what goes on inside your hub.


0 Votes 0 ·