Skip to content

Commit

Permalink
fix integration test (open-telemetry#2278)
Browse files Browse the repository at this point in the history
  • Loading branch information
lalitb authored Nov 6, 2024
1 parent 500d913 commit 0b716a7
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions opentelemetry-otlp/tests/integration_test/tests/logs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,15 @@ use log::{info, Level};
use opentelemetry::logs::LogError;
use opentelemetry::KeyValue;
use opentelemetry_appender_log::OpenTelemetryLogBridge;
use opentelemetry_otlp::{LogExporter, WithExportConfig};
use opentelemetry_otlp::LogExporter;
use opentelemetry_sdk::logs::LoggerProvider;
use opentelemetry_sdk::{logs as sdklogs, runtime, Resource};
use std::error::Error;
use std::fs::File;
use std::os::unix::fs::MetadataExt;

fn init_logs() -> Result<sdklogs::LoggerProvider, LogError> {
let exporter = LogExporter::builder()
.with_tonic()
.with_endpoint("0.0.0.0:4317")
.build()?;
let exporter = LogExporter::builder().with_tonic().build()?;

Ok(LoggerProvider::builder()
.with_batch_exporter(exporter, runtime::Tokio)
Expand Down

0 comments on commit 0b716a7

Please sign in to comment.