From a68b0aab47044c79ce0a4d7599b1230b3b2e2df6 Mon Sep 17 00:00:00 2001 From: bas smit Date: Sun, 22 Feb 2026 23:05:07 +0100 Subject: [PATCH 1/5] fix(source opentelemetry): log error If the HTTP opentelemetry source fails to build it is currently silently ignored, without logging any info to the 'user'. The only indication you have that something is wrong is that the log line about the http listener starting is _not_ there. With this change the error condition is logged the same way the gRPC error is logged. Before: ``` $ vector -c vector-otel.yaml ... 2026-02-23T09:15:50.053251Z INFO vector: Vector has started. debug="false" version="0.52.0" arch="aarch64" revision="ca5bf26 2025-12-16 14:56:07.290167996" 2026-02-23T09:15:50.053468Z INFO source{component_kind="source" component_id=otel component_type=opentelemetry}: vector::sources::util::grpc: Building gRPC server. address=127.0.0.1:4317 ``` now: ``` $ target/debug/vector --config vector-otel.yaml 2026-02-23T09:16:49.397436Z INFO vector: Vector has started. debug="true" version="0.54.0" arch="aarch64" revision="" 2026-02-23T09:16:49.398497Z INFO source{component_kind="source" component_id=otel component_type=opentelemetry}: vector::sources::util::grpc: Building gRPC server. address=127.0.0.1:4317 2026-02-23T09:16:49.400243Z ERROR source{component_kind="source" component_id=otel component_type=opentelemetry}: vector::sources::opentelemetry::config: Source future failed. error=TCP bind failed: Address family not supported by protocol family (os error 47) ``` --- src/sources/opentelemetry/config.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/sources/opentelemetry/config.rs b/src/sources/opentelemetry/config.rs index 96b290e7d9b09..072834a5fd08d 100644 --- a/src/sources/opentelemetry/config.rs +++ b/src/sources/opentelemetry/config.rs @@ -257,7 +257,10 @@ impl SourceConfig for OpentelemetryConfig { filters, cx.shutdown, self.http.keepalive.clone(), - ); + ) + .map_err(|error| { + error!(message = "Source future failed.", %error); + }); Ok(join(grpc_source, http_source).map(|_| Ok(())).boxed()) } From 798f501c66d3eb0f4ae29dfd5c86866c14f26b04 Mon Sep 17 00:00:00 2001 From: bas smit Date: Thu, 26 Feb 2026 10:12:46 +0100 Subject: [PATCH 2/5] improve error messages --- src/sources/opentelemetry/config.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sources/opentelemetry/config.rs b/src/sources/opentelemetry/config.rs index 072834a5fd08d..0a31c0c18b6ba 100644 --- a/src/sources/opentelemetry/config.rs +++ b/src/sources/opentelemetry/config.rs @@ -230,7 +230,7 @@ impl SourceConfig for OpentelemetryConfig { cx.shutdown.clone(), ) .map_err(|error| { - error!(message = "Source future failed.", %error); + error!(message = "OpenTelemetry gRPC source failed. Terminating.", %error); }); let http_tls_settings = MaybeTlsSettings::from_config(self.http.tls.as_ref(), true)?; @@ -259,7 +259,7 @@ impl SourceConfig for OpentelemetryConfig { self.http.keepalive.clone(), ) .map_err(|error| { - error!(message = "Source future failed.", %error); + error!(message = "OpenTelemetry HTTP source failed. Terminating", %error); }); Ok(join(grpc_source, http_source).map(|_| Ok(())).boxed()) From 8ec37d26d9fea7bfaf9a22fa7a3fd864a4e53778 Mon Sep 17 00:00:00 2001 From: bas smit Date: Thu, 26 Feb 2026 10:20:17 +0100 Subject: [PATCH 3/5] add changelog --- changelog.d/24708_log_error.fix.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 changelog.d/24708_log_error.fix.md diff --git a/changelog.d/24708_log_error.fix.md b/changelog.d/24708_log_error.fix.md new file mode 100644 index 0000000000000..8fe59ff8fb638 --- /dev/null +++ b/changelog.d/24708_log_error.fix.md @@ -0,0 +1,5 @@ +The `opentelemetry` source now logs an error if it fails to start up or during runtime. +This can happen when the configuration is invalid, for example trying to bind to the wrong +IP or when hitting the open file limit. + +author: fbs From e75bc0dc09058342dd26bff02a75ac27057e5924 Mon Sep 17 00:00:00 2001 From: Thomas Date: Thu, 26 Mar 2026 14:10:21 -0400 Subject: [PATCH 4/5] Fix CI errors Co-authored-by: Thomas --- changelog.d/24708_log_error.fix.md | 2 +- src/sources/opentelemetry/config.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/changelog.d/24708_log_error.fix.md b/changelog.d/24708_log_error.fix.md index 8fe59ff8fb638..d53626b09af05 100644 --- a/changelog.d/24708_log_error.fix.md +++ b/changelog.d/24708_log_error.fix.md @@ -2,4 +2,4 @@ The `opentelemetry` source now logs an error if it fails to start up or during r This can happen when the configuration is invalid, for example trying to bind to the wrong IP or when hitting the open file limit. -author: fbs +authors: fbs diff --git a/src/sources/opentelemetry/config.rs b/src/sources/opentelemetry/config.rs index 85c6c800ac9a3..ab69025d34722 100644 --- a/src/sources/opentelemetry/config.rs +++ b/src/sources/opentelemetry/config.rs @@ -357,7 +357,7 @@ impl SourceConfig for OpentelemetryConfig { self.http.keepalive.clone(), ) .map_err(|error| { - error!(message = "OpenTelemetry HTTP source failed. Terminating", %error); + error!(message = "OpenTelemetry HTTP source failed. Terminating.", %error); }); Ok(join(grpc_source, http_source).map(|_| Ok(())).boxed()) From 43c3eb9435607811c903bbd8a531ba158c755470 Mon Sep 17 00:00:00 2001 From: Pavlos Rontidis Date: Thu, 26 Mar 2026 15:43:57 -0400 Subject: [PATCH 5/5] fix(opentelemetry source): improve error message wording Co-Authored-By: Claude Sonnet 4.6 (1M context) --- src/sources/opentelemetry/config.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sources/opentelemetry/config.rs b/src/sources/opentelemetry/config.rs index ab69025d34722..827bbd213360d 100644 --- a/src/sources/opentelemetry/config.rs +++ b/src/sources/opentelemetry/config.rs @@ -328,7 +328,7 @@ impl SourceConfig for OpentelemetryConfig { cx.shutdown.clone(), ) .map_err(|error| { - error!(message = "OpenTelemetry gRPC source failed. Terminating.", %error); + error!(message = "OpenTelemetry source gRPC server failed.", %error); }); let http_tls_settings = MaybeTlsSettings::from_config(self.http.tls.as_ref(), true)?; @@ -357,7 +357,7 @@ impl SourceConfig for OpentelemetryConfig { self.http.keepalive.clone(), ) .map_err(|error| { - error!(message = "OpenTelemetry HTTP source failed. Terminating.", %error); + error!(message = "OpenTelemetry source HTTP server failed.", %error); }); Ok(join(grpc_source, http_source).map(|_| Ok(())).boxed())