opentelemetry-js/examples/metrics
legendecas f59c5b268b
chore: add markdown link checks (#2657)
Co-authored-by: Daniel Dyla <dyladan@users.noreply.github.com>
Co-authored-by: Valentin Marchaud <contact@vmarchaud.fr>
2021-12-11 21:31:36 +01:00
..
metrics feat(api-metrics): async instruments spec compliance (#2569) 2021-11-22 16:58:51 +01:00
README.md chore: add markdown link checks (#2657) 2021-12-11 21:31:36 +01:00
package.json chore: release proposal 0.25.0 (#2415) 2021-08-18 16:13:38 -04:00

README.md

Overview

OpenTelemetry metrics allow a user to collect data and export it to a metrics backend like Prometheus.

This is a simple example that demonstrates basic metrics collection and exports those metrics to a Prometheus compatible endpoint.

Installation

# from this directory
npm install

How to setup Prometheus please check Setup Prometheus

Run the Application

  • Run the example

Observer

npm run start:observer

Prometheus

  1. In prometheus search for "cpu_core_usage", "cpu_temp_per_app", "cpu_usage_per_app"
  1. Prometheus Scrape Endpoint http://localhost:9464/metrics
  2. Prometheus graph http://localhost:9090/graph

Example

Screenshot of the running example Screenshot of the running example Screenshot of the running example

LICENSE

Apache License 2.0