Skip to content

Commit abd0b0f

Browse files
aggregation validate: use constants for output
1 parent 6ef5d10 commit abd0b0f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

opentelemetry-sdk/src/metrics/aggregation.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,12 @@ impl Aggregation {
130130
Aggregation::Base2ExponentialHistogram { max_scale, .. } => {
131131
if *max_scale > EXPO_MAX_SCALE {
132132
return Err(MetricError::Config(format!(
133-
"aggregation: exponential histogram: max scale ({max_scale}) is greater than 20",
133+
"aggregation: exponential histogram: max scale ({max_scale}) is greater than {}", EXPO_MAX_SCALE
134134
)));
135135
}
136136
if *max_scale < EXPO_MIN_SCALE {
137137
return Err(MetricError::Config(format!(
138-
"aggregation: exponential histogram: max scale ({max_scale}) is less than -10",
138+
"aggregation: exponential histogram: max scale ({max_scale}) is less than {}", EXPO_MIN_SCALE
139139
)));
140140
}
141141

0 commit comments

Comments
 (0)