From 58c6f609496e4ed08c0735796feac2bae85a1e8c Mon Sep 17 00:00:00 2001 From: Dmitry Aleksandrov Date: Fri, 20 Jan 2023 17:13:37 +0200 Subject: [PATCH] [4.x.] - Deprecate MicroProfile Tracing (#5909) * MicroProfile Tracing removed and marked for deprecation. * Fix TCK * Fix Integration with Zipkin * Fix Integration with Zipkin. Fix Copyright. * Fix OpenTracing warning message. Fix module deprecation. * Fix Deprecated Since descriptor handler. --- .../helidon/common/features/processor/FeatureHandler.java | 6 +++--- docs/mp/tracing.adoc | 5 ++++- microprofile/bundles/helidon-microprofile/pom.xml | 6 +----- .../helidon-microprofile/src/main/java/module-info.java | 3 +-- microprofile/tests/tck/tck-opentracing/pom.xml | 7 ++++++- microprofile/tracing/src/main/java/module-info.java | 5 +++-- tests/integration/zipkin-mp-2.2/pom.xml | 6 +++++- 7 files changed, 23 insertions(+), 15 deletions(-) diff --git a/common/features/processor/src/main/java/io/helidon/common/features/processor/FeatureHandler.java b/common/features/processor/src/main/java/io/helidon/common/features/processor/FeatureHandler.java index a1098ed2c96..8800ca5112c 100644 --- a/common/features/processor/src/main/java/io/helidon/common/features/processor/FeatureHandler.java +++ b/common/features/processor/src/main/java/io/helidon/common/features/processor/FeatureHandler.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022 Oracle and/or its affiliates. + * Copyright (c) 2022, 2023 Oracle and/or its affiliates. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -110,12 +110,12 @@ private void processModule(Element moduleElement) { annotation.getElementValues() .forEach((method, value) -> { if (method.getSimpleName().contentEquals("since")) { - descriptor.since((String) value.getValue()); + descriptor.deprecatedSince((String) value.getValue()); } }); if (descriptor.noDeprecatedSince()) { messager.printMessage(Diagnostic.Kind.ERROR, "Failed to process feature metadata annotation processor. " - + " Module " + moduleName + " has @Deprecated without since. Since must be defined"); + + " Module " + moduleName + " has @Deprecated without since. Since must be defined."); throw new IllegalStateException("Deprecated without since in module " + moduleName); } break; diff --git a/docs/mp/tracing.adoc b/docs/mp/tracing.adoc index 3bcced435ea..c817744ebce 100644 --- a/docs/mp/tracing.adoc +++ b/docs/mp/tracing.adoc @@ -1,6 +1,6 @@ /////////////////////////////////////////////////////////////////////////////// - Copyright (c) 2018, 2022 Oracle and/or its affiliates. + Copyright (c) 2018, 2023 Oracle and/or its affiliates. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -39,6 +39,9 @@ include::{rootdir}/includes/mp.adoc[] == Overview +WARNING: The OpenTracing Specification that MP OpenTracing is based on is no longer maintained. +The MP OpenTracing specification is no longer required by MicroProfile. This feature is marked as `@Deprecated` in Helidon. The specification is Superseded by link:https://github.com/eclipse/microprofile-telemetry[MicroProfile Telemetry specification]. + Distributed tracing is a critical feature of micro-service based applications, since it traces workflow both within a service and across multiple services. This provides insight to sequence and timing data for specific blocks of work, which helps you identify performance and operational issues. Helidon MP includes support for distributed tracing diff --git a/microprofile/bundles/helidon-microprofile/pom.xml b/microprofile/bundles/helidon-microprofile/pom.xml index 502ce87f511..d66cccddf66 100644 --- a/microprofile/bundles/helidon-microprofile/pom.xml +++ b/microprofile/bundles/helidon-microprofile/pom.xml @@ -1,7 +1,7 @@