This sample Azure IoT Edge solution demonstrates how to store timeseries data from IoT sensors in RedisTimeSeries. The Simulated Temperature Sensor edge module is used to generate temperature, pressure and humidity readings. These readings are then routed to our custom C# edge module which stores them in RedisTimeSeries.
- Connects to Redis with Unix Sockets instead of the TCP port.
- Makes .NET runtime metrics available in Prometheus format.
- Scrapes Redis usage metrics in Prometheus format.
- Exposes an Azure IoT Hub Direct Method named
GetTimeSeriesInfo
. This method can be used to retrieve statistics about the stored data in RedisTimeSeries. - Provides Grafana dashboards for visualizing timeseries and above Prometheus data sources, see below.
- Azure IoT Hub with an edge device provisioned
- Docker Community Edition
- .NET Core 3.1
- Python 3.8
- Azure IoT EdgeHub Dev Tool
- Visual Studio Code with the following extensions
The .env
file can be modified for container version, container host names and to use an Azure Container Registry instead of a local docker registry.
Simulated timeseries dashboard was created using the Redis Data Source for Grafana.
Redis usage dashboard was created using the Prometheus Redis Metrics Exporter.
.NET runtime metrics dashboard was created using prometheus-net.DotNetMetrics.