Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/prathamesh-sonpatki/otel-to-prom
https://github.com/prathamesh-sonpatki/otel-to-prom
Last synced: 29 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/prathamesh-sonpatki/otel-to-prom
- Owner: prathamesh-sonpatki
- Created: 2023-09-02T15:48:02.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-02T17:24:06.000Z (about 1 year ago)
- Last Synced: 2024-05-02T01:05:13.091Z (6 months ago)
- Language: Python
- Size: 1000 Bytes
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Demo apps to send Otel metrics to Prometheus
### Running Prometheus locally
``` shell
prometheus --enable-feature=otlp-write-receiver
```> Assume that you have a standard `prometheus.yml` in the same directory.
### Sending Otel metrics to Prometheus
``` shell
cd python
pip3 install Flask opentelemetry-api opentelemetry-sdk opentelemetry-exporter-otlp
python3 app.py
```This will push metrics to `localhost:9090/api/v1/otlp/v1/metrics` The host is standard host where Prometheus runs by default and the URL path is the OTLP endpoint of Prometheus which accepts native OpenTelemetry metrics.