From 36f0dc4c6eddfcc2c7f2a97c3d9866efe2ae53ad Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Mon, 7 Oct 2024 23:16:35 +0200 Subject: [PATCH 1/4] Fixes #3077 --- DEPRECATED.md | 40 +------------------ .../opentelemetry/trace/propagation/jaeger.h | 6 +-- api/test/trace/propagation/CMakeLists.txt | 15 +------ 3 files changed, 3 insertions(+), 58 deletions(-) diff --git a/DEPRECATED.md b/DEPRECATED.md index 0632f50503..eea861ffe6 100644 --- a/DEPRECATED.md +++ b/DEPRECATED.md @@ -46,45 +46,7 @@ N/A ## [opentelemetry-cpp API] -### Jaeger propagator - -#### Announcement (Jaeger) - -* Version: 1.8.2 -* Date: 2023-01-31 -* PR: [DEPRECATION] Deprecate the Jaeger exporter - [#1923](https://github.com/open-telemetry/opentelemetry-cpp/pull/1923) - -This PR also listed the Jaeger propagator as deprecated. - -#### Motivation (Jaeger) - -The Jaeger Exporter is now (July 2023) removed from the OpenTelemetry specification. - -The Jaeger Propagator remains, because changing propagation is a longer -process compared to changing an export format. - -New deployments however are encouraged to use a W3C compliant propagator, -and avoid the Jaeger propagator, which is now deprecated. - -#### Scope (Jaeger) - -The following are deprecated and planned for removal: - -* the API header `opentelemetry/trace/propagation/jaeger.h`, including: - * the C++ class `JaegerPropagator` - -#### Mitigation (Jaeger) - -Use a W3C compliant propagator instead. - -That is, use class HttpTraceContext and "traceparent" tags. - -Do not use class JaegerPropagator and "uber-trace-id" tags. - -#### Planned removal (Jaeger) - -No date set yet for the Jaeger Propagator. +N/A ## [opentelemetry-cpp SDK] diff --git a/api/include/opentelemetry/trace/propagation/jaeger.h b/api/include/opentelemetry/trace/propagation/jaeger.h index 1f0195a248..45a9370919 100644 --- a/api/include/opentelemetry/trace/propagation/jaeger.h +++ b/api/include/opentelemetry/trace/propagation/jaeger.h @@ -3,10 +3,6 @@ #pragma once -#ifdef OPENTELEMETRY_NO_DEPRECATED_CODE -# error "header is deprecated." -#endif - #include "detail/hex.h" #include "detail/string.h" #include "opentelemetry/context/propagation/text_map_propagator.h" @@ -21,7 +17,7 @@ namespace propagation static const nostd::string_view kJaegerTraceHeader = "uber-trace-id"; -class OPENTELEMETRY_DEPRECATED JaegerPropagator : public context::propagation::TextMapPropagator +class JaegerPropagator : public context::propagation::TextMapPropagator { public: void Inject(context::propagation::TextMapCarrier &carrier, diff --git a/api/test/trace/propagation/CMakeLists.txt b/api/test/trace/propagation/CMakeLists.txt index a1cfcf83ee..1d8ead92cd 100644 --- a/api/test/trace/propagation/CMakeLists.txt +++ b/api/test/trace/propagation/CMakeLists.txt @@ -3,7 +3,7 @@ add_subdirectory(detail) -foreach(testname http_text_format_test b3_propagation_test) +foreach(testname http_text_format_test b3_propagation_test jaeger_propagation_test) add_executable(${testname} "${testname}.cc") target_link_libraries(${testname} ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} opentelemetry_api) @@ -12,16 +12,3 @@ foreach(testname http_text_format_test b3_propagation_test) TEST_PREFIX trace. TEST_LIST ${testname}) endforeach() - -if(NOT WITH_NO_DEPRECATED_CODE) - foreach(testname jaeger_propagation_test) - - add_executable(${testname} "${testname}.cc") - target_link_libraries(${testname} ${GTEST_BOTH_LIBRARIES} - ${CMAKE_THREAD_LIBS_INIT} opentelemetry_api) - gtest_add_tests( - TARGET ${testname} - TEST_PREFIX trace. - TEST_LIST ${testname}) - endforeach() -endif() From 266c7636ea19358bf3686b305209582a5ba6d391 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Mon, 7 Oct 2024 23:33:15 +0200 Subject: [PATCH 2/4] Changelog entry, format. --- CHANGELOG.md | 16 ++++++++++++++++ api/test/trace/propagation/CMakeLists.txt | 3 ++- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 66d60f3513..6bd3d4e00c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,22 @@ Increment the: * MINOR version when you add functionality in a backwards compatible manner, and * PATCH version when you make backwards compatible bug fixes. +## [Next Unreleased] - temporary section, waiting to publish 1.17.0 first. + +* [API] Jaeger Propagator should not be deprecated + [#3086](https://github.com/open-telemetry/opentelemetry-cpp/pull/3086) + +Important changes: + +* [API] Jaeger Propagator should not be deprecated + [#3086](https://github.com/open-telemetry/opentelemetry-cpp/pull/3086) + + * Deprecation of the Jaeger propagator, as announced on 2023-01-31 + in version 1.8.2, is now reverted. + * This deprecation turned out to be not justified, + as the Jaeger propagator can be used without the (now removed) + Jaeger exporter. + ## [Unreleased] * [CI] Add a clang-tidy build diff --git a/api/test/trace/propagation/CMakeLists.txt b/api/test/trace/propagation/CMakeLists.txt index 1d8ead92cd..11760122a4 100644 --- a/api/test/trace/propagation/CMakeLists.txt +++ b/api/test/trace/propagation/CMakeLists.txt @@ -3,7 +3,8 @@ add_subdirectory(detail) -foreach(testname http_text_format_test b3_propagation_test jaeger_propagation_test) +foreach(testname http_text_format_test b3_propagation_test + jaeger_propagation_test) add_executable(${testname} "${testname}.cc") target_link_libraries(${testname} ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} opentelemetry_api) From 409b5d7dcc64ad720a41b019c9510df3848745bb Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Tue, 8 Oct 2024 00:13:22 +0200 Subject: [PATCH 3/4] Adjust after 1.17.0 merge --- CHANGELOG.md | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 79faf2b41b..540479eb97 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,7 +13,7 @@ Increment the: * MINOR version when you add functionality in a backwards compatible manner, and * PATCH version when you make backwards compatible bug fixes. -## [Next Unreleased] - temporary section, waiting to publish 1.17.0 first. +## [Unreleased] * [API] Jaeger Propagator should not be deprecated [#3086](https://github.com/open-telemetry/opentelemetry-cpp/pull/3086) @@ -29,8 +29,6 @@ Important changes: as the Jaeger propagator can be used without the (now removed) Jaeger exporter. -## [Unreleased] - ## [1.17 2024-10-07] * [CI] Add a clang-tidy build From b5cceb10661e6a84726bbff465b471d99da6e573 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Tue, 8 Oct 2024 00:17:12 +0200 Subject: [PATCH 4/4] Format --- api/test/trace/propagation/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/test/trace/propagation/CMakeLists.txt b/api/test/trace/propagation/CMakeLists.txt index 11760122a4..f55c738165 100644 --- a/api/test/trace/propagation/CMakeLists.txt +++ b/api/test/trace/propagation/CMakeLists.txt @@ -4,7 +4,7 @@ add_subdirectory(detail) foreach(testname http_text_format_test b3_propagation_test - jaeger_propagation_test) + jaeger_propagation_test) add_executable(${testname} "${testname}.cc") target_link_libraries(${testname} ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} opentelemetry_api)