Skip to content

Commit 2f65b54

Browse files
lalitbcijothomas
andauthored
Global error handler cleanup - ManualReader (#2236)
Co-authored-by: Cijo Thomas <cijo.thomas@gmail.com>
1 parent 45b4f82 commit 2f65b54

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

opentelemetry-sdk/src/metrics/manual_reader.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ use std::{
44
};
55

66
use opentelemetry::{
7-
global,
87
metrics::{MetricsError, Result},
8+
otel_debug,
99
};
1010

1111
use super::{
@@ -77,9 +77,9 @@ impl MetricReader for ManualReader {
7777
if inner.sdk_producer.is_none() {
7878
inner.sdk_producer = Some(pipeline);
7979
} else {
80-
global::handle_error(MetricsError::Config(
81-
"duplicate reader registration, did not register manual reader".into(),
82-
))
80+
otel_debug!(
81+
name: "ManualReader.DuplicateRegistration",
82+
message = "The pipeline is already registered to the Reader. Registering pipeline multiple times is not allowed.");
8383
}
8484
});
8585
}

0 commit comments

Comments
 (0)