Feeding Prometheus with data
In this section, you will learn how to ingest data into Prometheus. Let’s look at all the different options that you have.
Prometheus clients
You can use client libraries to expose metrics on an endpoint that can be scraped by Prometheus using HTTP requests.
There are several language options you can select. You can find a complete list at https://prometheus.io/docs/instrumenting/clientlibs/.
You should choose the language that you used to implement your IoT application in your gateway or IoT device.
The idea behind the client libraries is to implement an endpoint that gets all the metrics that you need from the host and exposes them using HTTP. Then, Prometheus can scrap them by connecting to the endpoint through HTTP requests.
The client will serve the metrics using the metric types that we looked at in the previous section.
Exporters
You can expose metrics from endpoints using exporters. These are pieces of software that...