Skip to content

Commit 0185d5e

Browse files
committed
Install rustls provider before telemetry init
1 parent 3f26fcf commit 0185d5e

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ impl AppState {
152152
}
153153
}
154154

155-
fn install_default_rustls_provider() {
155+
pub(crate) fn install_default_rustls_provider() {
156156
let _ = rustls::crypto::ring::default_provider().install_default();
157157
}
158158

src/telemetry.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,7 @@ impl opentelemetry_http::HttpClient for AwcOtlpHttpClient {
182182

183183
/// Initializes logging / tracing. Returns whether `OTel` was activated.
184184
pub fn init_telemetry() -> anyhow::Result<bool> {
185+
crate::install_default_rustls_provider();
185186
init_telemetry_with_log_layer(logfmt::LogfmtLayer::new())
186187
}
187188

0 commit comments

Comments
 (0)