@@ -223,7 +223,7 @@ impl HttpExporterBuilder {
223
223
224
224
/// Create a log exporter with the current configuration
225
225
#[ cfg( feature = "logs" ) ]
226
- pub fn build_log_exporter ( mut self ) -> opentelemetry :: logs:: LogResult < crate :: LogExporter > {
226
+ pub fn build_log_exporter ( mut self ) -> opentelemetry_sdk :: logs:: LogResult < crate :: LogExporter > {
227
227
use crate :: {
228
228
OTEL_EXPORTER_OTLP_LOGS_ENDPOINT , OTEL_EXPORTER_OTLP_LOGS_HEADERS ,
229
229
OTEL_EXPORTER_OTLP_LOGS_TIMEOUT ,
@@ -244,7 +244,7 @@ impl HttpExporterBuilder {
244
244
pub fn build_metrics_exporter (
245
245
mut self ,
246
246
temporality : opentelemetry_sdk:: metrics:: data:: Temporality ,
247
- ) -> opentelemetry :: metrics:: MetricResult < crate :: MetricExporter > {
247
+ ) -> opentelemetry_sdk :: metrics:: MetricResult < crate :: MetricExporter > {
248
248
use crate :: {
249
249
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT , OTEL_EXPORTER_OTLP_METRICS_HEADERS ,
250
250
OTEL_EXPORTER_OTLP_METRICS_TIMEOUT ,
@@ -315,7 +315,7 @@ impl OtlpHttpClient {
315
315
fn build_logs_export_body (
316
316
& self ,
317
317
logs : LogBatch < ' _ > ,
318
- ) -> opentelemetry :: logs:: LogResult < ( Vec < u8 > , & ' static str ) > {
318
+ ) -> opentelemetry_sdk :: logs:: LogResult < ( Vec < u8 > , & ' static str ) > {
319
319
use opentelemetry_proto:: tonic:: collector:: logs:: v1:: ExportLogsServiceRequest ;
320
320
let resource_logs = group_logs_by_resource_and_scope ( logs, & self . resource ) ;
321
321
let req = ExportLogsServiceRequest { resource_logs } ;
@@ -324,7 +324,7 @@ impl OtlpHttpClient {
324
324
#[ cfg( feature = "http-json" ) ]
325
325
Protocol :: HttpJson => match serde_json:: to_string_pretty ( & req) {
326
326
Ok ( json) => Ok ( ( json. into ( ) , "application/json" ) ) ,
327
- Err ( e) => Err ( opentelemetry :: logs:: LogError :: from ( e. to_string ( ) ) ) ,
327
+ Err ( e) => Err ( opentelemetry_sdk :: logs:: LogError :: from ( e. to_string ( ) ) ) ,
328
328
} ,
329
329
_ => Ok ( ( req. encode_to_vec ( ) , "application/x-protobuf" ) ) ,
330
330
}
@@ -334,7 +334,7 @@ impl OtlpHttpClient {
334
334
fn build_metrics_export_body (
335
335
& self ,
336
336
metrics : & mut opentelemetry_sdk:: metrics:: data:: ResourceMetrics ,
337
- ) -> opentelemetry :: metrics:: MetricResult < ( Vec < u8 > , & ' static str ) > {
337
+ ) -> opentelemetry_sdk :: metrics:: MetricResult < ( Vec < u8 > , & ' static str ) > {
338
338
use opentelemetry_proto:: tonic:: collector:: metrics:: v1:: ExportMetricsServiceRequest ;
339
339
340
340
let req: ExportMetricsServiceRequest = ( & * metrics) . into ( ) ;
@@ -343,7 +343,9 @@ impl OtlpHttpClient {
343
343
#[ cfg( feature = "http-json" ) ]
344
344
Protocol :: HttpJson => match serde_json:: to_string_pretty ( & req) {
345
345
Ok ( json) => Ok ( ( json. into ( ) , "application/json" ) ) ,
346
- Err ( e) => Err ( opentelemetry:: metrics:: MetricError :: Other ( e. to_string ( ) ) ) ,
346
+ Err ( e) => Err ( opentelemetry_sdk:: metrics:: MetricError :: Other (
347
+ e. to_string ( ) ,
348
+ ) ) ,
347
349
} ,
348
350
_ => Ok ( ( req. encode_to_vec ( ) , "application/x-protobuf" ) ) ,
349
351
}
0 commit comments