| Crates.io | llm-config-metrics |
| lib.rs | llm-config-metrics |
| version | 0.5.0 |
| created_at | 2025-11-21 21:32:28.485859+00 |
| updated_at | 2025-11-21 21:32:28.485859+00 |
| description | Prometheus-based metrics collection and export for monitoring configuration access, performance, and usage patterns |
| homepage | https://github.com/globalbusinessadvisors/llm-config-manager |
| repository | https://github.com/globalbusinessadvisors/llm-config-manager |
| max_upload_size | |
| id | 1944295 |
| size | 58,414 |
Prometheus-based metrics collection and export for monitoring configuration access, performance, and usage patterns in LLM Config Manager.
[dependencies]
llm-config-metrics = "0.5.0"
use llm_config_metrics::MetricsCollector;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let metrics = MetricsCollector::new();
// Record metric
metrics.record_request_duration("get_config", 0.045)?;
metrics.increment_counter("config_access", &["production"])?;
// Export metrics (Prometheus format)
let exported = metrics.export()?;
println!("{}", exported);
Ok(())
}
config_requests_total: Total configuration requestsconfig_request_duration_seconds: Request latency histogramconfig_cache_hits_total: Cache hit counterconfig_errors_total: Error counter by typeLicensed under the Apache License, Version 2.0.