mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-08-17 09:07:48 +00:00
Add metrics to web endpoint
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
use std::time::Duration;
|
||||
|
||||
use opentelemetry::sdk::{
|
||||
trace::{self, IdGenerator, Sampler},
|
||||
trace::{self, IdGenerator},
|
||||
Resource,
|
||||
};
|
||||
use opentelemetry::KeyValue;
|
||||
@@ -24,7 +24,6 @@ pub fn init_tracing(export_to: &str, node_id: Uuid) -> Result<(), Error> {
|
||||
.with_trace_config(
|
||||
trace::config()
|
||||
.with_id_generator(IdGenerator::default())
|
||||
.with_sampler(Sampler::TraceIdRatioBased(0.01f64))
|
||||
.with_resource(Resource::new(vec![
|
||||
KeyValue::new("service.name", "garage"),
|
||||
KeyValue::new("service.instance.id", node_id),
|
||||
|
||||
Reference in New Issue
Block a user