#open-telemetry #metrics #cpu #memory #disk #networking

opentelemetry-system-metrics

System metric export through Opentelemetry

11 releases

0.3.1 Mar 20, 2025
0.2.0 Jun 3, 2024
0.1.8 Mar 15, 2024
0.1.6 Nov 20, 2023
0.1.1 Jun 24, 2022

#369 in Filesystem

Download history 557/week @ 2024-12-22 1266/week @ 2024-12-29 1322/week @ 2025-01-05 2339/week @ 2025-01-12 515/week @ 2025-01-19 913/week @ 2025-01-26 1287/week @ 2025-02-02 176/week @ 2025-02-09 1228/week @ 2025-02-16 1150/week @ 2025-02-23 4550/week @ 2025-03-02 5132/week @ 2025-03-09 5015/week @ 2025-03-16 4077/week @ 2025-03-23 2439/week @ 2025-03-30 4330/week @ 2025-04-06

16,510 downloads per month
Used in 3 crates (via dora-metrics)

Apache-2.0

20KB
154 lines

This is my awesome crate Enabling system metrics from process to be observed using opentelemetry. Current metrics observed are:

  • CPU
  • Memory
  • Disk
  • Network

Getting started

use opentelemetry::global;
use opentelemetry_system_metrics::init_process_observer;

let meter = global::meter("process-meter");
init_process_observer(meter);

opentelemetry-system-metrics

This is my awesome crate enabling process level system metrics using opentelemetry.

Current metrics observed are:

  • CPU
  • Memory
  • Disk
  • Network
  • GPU Memory

Getting started

cargo add opentelemetry_system_metrics
use opentelemetry::global;
use opentelemetry_system_metrics::init_process_observer;

let meter = global::meter("process-meter");
init_process_observer(meter);

To get started with InfluxDB, you should create an account at InfluxDB Cloud, create a new telegraf opentelemetry exporter.

  • Ex:
export INFLUX_TOKEN=<PROVIDED TOKEN>
telegraf --config <PROVIDED LINK>
cargo run --example otlp-tokio-metrics

Dependencies

~6–12MB
~134K SLoC