Giter VIP home page Giter VIP logo

azure-iothub-exporter's Introduction

build deploy

Azure IoT Hub exporter

Azure IoT Hub exporter listens to Azure IoT Hub messages endpoint and exposes IoT Edge metrics to Prometheus.

Azure IoT Hub exporter

IoT Edge metrics are exported to IoT Hub by the metrics collector module as it is described in Collect and transport metrics approach (Option 2) via device-to-cloud messages. Azure IoT Hub exporter converts the metrics messages to Prometheus format and exposes them to be scrapped by Prometheus server.

Motivation

Collect and transport metrics describes how to deliver metrics to IoT Hub via standard device-to-cloud channel. It's also possible to build a cloud workflow to push the metrics to Log Analytics workspace and consume them with Azure Workbooks and Azure Alerts. But what if we build our observability approach on top of Prometheus and Grafana? Metrics are exposed by IoT Edge modules in Prometheues format and we want them to land in a Prometheus server so that we can use PromQL to build Grafana dashboards and Prometheus alerts. The purpose of Azure IoT Hub exporter is to close the gap between IoT Hub and Prometheus server.

Dashboard

Installation

Add Azure IoT Hub exporter repository to Helm repos:

helm repo add azure-iothub-exporter https://microsoft.github.io/azure-iothub-exporter/

Install Azure IoT Hub exporter:

helm upgrade -i azure-iothub-exporter azure-iothub-exporter/azure-iothub-exporter \
--namespace <NAMESPACE> \
--set eventHubConnectionString=<IoT Hub messages endpoint connection string>

Refer to Read device-to-cloud messages from the built-in endpoint for the details on the IoT Hub messages endpoint connection string.

Prometheus configuration

Add the following job defintion to the prometheus config:

- job_name: azure-iothub-exporter
  scrape_interval: 1m
  metrics_path: /iotmetrics
  static_configs:
  - targets: ["azure-iothub-exporter.<NAMESPACE>.svc.cluster.local:8080"]

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

azure-iothub-exporter's People

Contributors

eedorenko avatar microsoft-github-policy-service[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

azure-iothub-exporter's Issues

Issue with connection string

I installed the bundle with helm as mentioned.
I used the EventHub connection string like...
Endpoint=sb://..........servicebus.windows.net/;SharedAccessKeyName=listenPolicy;SharedAccessKey=.....;EntityPath=....

But I get the error
level=fatal msg="key \"SharedAccessKeyName\" must not be empty"

kubectl:
monitoring azure-iothub-exporter-8fd9785c4-jc2c5 0/1 CrashLoopBackOff 1 (3s ago) 6s

Do you have any idea what is wrong?

Docker build throws error "go mod download: github.com/Azure/[email protected]+incompatible: ... x509: certificate signed by unknown authority"

Building the repo throws the below error at step RUN go mod download. Any idea?
docker build -t telemetry-exporter .

=> ERROR [build 5/7] RUN go mod download 41.8s

[build 5/7] RUN go mod download:
#9 41.56 go mod download: github.com/Azure/[email protected]+incompatible: Get "https://storage.googleapis.com/proxy-golang-org-prod/2......
: x509: certificate signed by unknown authority


executor failed running [/bin/sh -c go mod download]: exit code: 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.