diff --git a/implementations/rust/ockam/ockam_api/src/logs/logging_options.rs b/implementations/rust/ockam/ockam_api/src/logs/logging_options.rs index 0c3eaff181e..ab7e608bc87 100644 --- a/implementations/rust/ockam/ockam_api/src/logs/logging_options.rs +++ b/implementations/rust/ockam/ockam_api/src/logs/logging_options.rs @@ -109,7 +109,7 @@ impl OckamLogFormat { } fn format_timestamp(&self, writer: &mut Writer<'_>) -> std::fmt::Result { - let now = chrono::Utc::now().format("%Y-%m-%d %H:%M:%S%.3f"); + let now = chrono::Utc::now().format("%Y-%m-%dT%H:%M:%S%.6f"); if writer.has_ansi_escapes() { let style = Style::new().dimmed(); write!(writer, "{}", style.prefix())?; diff --git a/implementations/rust/ockam/ockam_api/src/logs/setup.rs b/implementations/rust/ockam/ockam_api/src/logs/setup.rs index 080b2463209..2d02ba0c43c 100644 --- a/implementations/rust/ockam/ockam_api/src/logs/setup.rs +++ b/implementations/rust/ockam/ockam_api/src/logs/setup.rs @@ -3,7 +3,6 @@ use opentelemetry::trace::TracerProvider; use opentelemetry::{global, KeyValue}; use opentelemetry_appender_tracing::layer::OpenTelemetryTracingBridge; use opentelemetry_otlp::WithExportConfig; -use opentelemetry_sdk as sdk; use opentelemetry_sdk::export::logs::LogExporter; use opentelemetry_sdk::export::trace::SpanExporter; use opentelemetry_sdk::logs::{BatchLogProcessor, LoggerProvider}; diff --git a/implementations/rust/ockam/ockam_api/src/nodes/service/relay.rs b/implementations/rust/ockam/ockam_api/src/nodes/service/relay.rs index 58713f74fc6..f51b9fcbbc0 100644 --- a/implementations/rust/ockam/ockam_api/src/nodes/service/relay.rs +++ b/implementations/rust/ockam/ockam_api/src/nodes/service/relay.rs @@ -204,7 +204,6 @@ impl NodeManager { info!( %alias, %address, ?authorized, ?relay_address, - forwarding_route = ?relay_info.forwarding_route(), remote_address = ?relay_info.remote_address(), "relay created" ); diff --git a/implementations/rust/ockam/ockam_api/tests/logging_tracing.rs b/implementations/rust/ockam/ockam_api/tests/logging_tracing.rs index 12c010df860..a142e7126ac 100644 --- a/implementations/rust/ockam/ockam_api/tests/logging_tracing.rs +++ b/implementations/rust/ockam/ockam_api/tests/logging_tracing.rs @@ -5,11 +5,6 @@ use ockam_api::logs::{ use opentelemetry::global; use opentelemetry::trace::Tracer; - -use opentelemetry_sdk as sdk; -use sdk::testing::logs::*; -use sdk::testing::trace::*; - use opentelemetry_sdk::testing::logs::InMemoryLogsExporter; use opentelemetry_sdk::testing::trace::InMemorySpanExporter; use std::fs; diff --git a/implementations/rust/ockam/ockam_command/src/node/create/foreground.rs b/implementations/rust/ockam/ockam_command/src/node/create/foreground.rs index a6dbab4941a..ea50a499708 100644 --- a/implementations/rust/ockam/ockam_command/src/node/create/foreground.rs +++ b/implementations/rust/ockam/ockam_command/src/node/create/foreground.rs @@ -54,7 +54,7 @@ impl CreateCommand { // Set node_name so that node can isolate its data in the storage from other nodes self.get_or_create_identity(&opts, &self.identity).await?; let _notification_handler = if self.foreground_args.child_process { - // If enabled, the user's terminal will receive notifications + // If enabled, the user's terminal would receive notifications // from the node after the command exited. None } else { diff --git a/implementations/rust/ockam/ockam_command/src/node/show.rs b/implementations/rust/ockam/ockam_command/src/node/show.rs index 52c9938ae01..2a0278fe924 100644 --- a/implementations/rust/ockam/ockam_command/src/node/show.rs +++ b/implementations/rust/ockam/ockam_command/src/node/show.rs @@ -171,7 +171,7 @@ pub async fn is_node_up( .ask_with_timeout::<(), NodeStatus>(ctx, api::query_status(), Duration::from_secs(1)) .await { - if status.status.is_running() { + if status.process_status.is_running() { return Ok(true); } } diff --git a/implementations/rust/ockam/ockam_command/src/relay/create.rs b/implementations/rust/ockam/ockam_command/src/relay/create.rs index 479110f6693..a27711c4774 100644 --- a/implementations/rust/ockam/ockam_command/src/relay/create.rs +++ b/implementations/rust/ockam/ockam_command/src/relay/create.rs @@ -91,8 +91,6 @@ impl Command for CreateCommand { let alias = cmd.relay_name(); let return_timing = cmd.return_timing(); - // let _notification_handler = NotificationHandler::start(&opts.state, opts.terminal.clone()); - let node = BackgroundNodeClient::create(ctx, &opts.state, &cmd.to).await?; let relay_info = { if at.starts_with(Project::CODE) && cmd.authorized.is_some() { diff --git a/implementations/rust/ockam/ockam_node/src/context/receive_message.rs b/implementations/rust/ockam/ockam_node/src/context/receive_message.rs index 8334d0b32c9..327ff927ff3 100644 --- a/implementations/rust/ockam/ockam_node/src/context/receive_message.rs +++ b/implementations/rust/ockam/ockam_node/src/context/receive_message.rs @@ -61,7 +61,7 @@ impl Context { pub(crate) async fn receiver_next(&mut self) -> Result> { loop { let relay_msg = if let Some(msg) = self.receiver.recv().await.map(|msg| { - trace!("{}: received new message!", self.address()); + trace!(address=%self.address(), "received new message!"); // First we update the mailbox fill metrics self.mailbox_count.fetch_sub(1, Ordering::Acquire);