IoT Edge module which visualizes incoming messages and outputs them unchanged. It's great for getting insights into your IoT Edge routing.
This is a C# .Net Standard module, written for Azure IoTEdge version GA.
This module is a simple module that helps to go get insights about module outputs and outputted messages.
It's great to check the output from third party modules (eg. the Azure Stream Analytics module).
You can just put it next to another route to listen to the communication between these two routes.
Note: This module is not capable of splitting multiple streams of input data flowing through it.
A version generated for Docker Linux can be found at https://hub.docker.com/r/iotedgefoundation/iot-edge-echo/
You can pull it with docker pull iotedgefoundation/iot-edge-echo but I suggest using a more specific name like iotedgefoundation/iot-edge-echo:3.0.7-amd64 (for Linux containers) when you deploy it using the Azure portal or the IoT Edge deployment manifest.
This module does not support 'desired' or 'reported' properties.
This module ingests telemetry messages using input input1.
The messages passed through are sent using output output1
The output messages are the same as inputted message except for one extra property:
Properties.Add("content-type", "application/edge-output1-echo-json");
Note: If the incoming message is not a valid JSON message, the message will throw an exception instead of output.
Use this example route:
{
"routes": {
"heartbeatToEcho": "FROM /messages/modules/heartbeat/outputs/output1 INTO BrokeredEndpoint(\"/modules/echo/inputs/input1\")",
"route": "FROM /messages/modules/echo/outputs/output1/* INTO $upstream"
}
}
On initialize, this module exposes all available environment variables in the logging.
Messages which ContentEncoding is "gzip" and ContentType is "application/zip" will be unzipped using Gzip decompression.
Messages which ContentEncoding is "defalte" and ContentType is "application/zip" will be unzipped using Deflate decompression.
The library ZipHelper used, follows the System.IO.Compression guidelines.
This logic is licensed under the MIT license.
Want to contribute? Throw in a pull request....
Sourcecode is available here.
Want to know more about me? Check out my blog