From 20054f937abc1c8ac1b07b355a2b357ff5c5de12 Mon Sep 17 00:00:00 2001 From: Brian Harrington Date: Wed, 10 Jul 2024 09:15:35 -0500 Subject: [PATCH] aws: deprecate classes Deprecate these classe to encourage users to transition to V2 before [AWS support for V1] ends. [AWS support for V1]: https://aws.amazon.com/blogs/developer/announcing-end-of-support-for-aws-sdk-for-java-v1-x-on-december-31-2025/ --- .../com/netflix/spectator/aws/SpectatorMetricCollector.java | 4 ++++ .../spectator/aws/SpectatorRequestMetricCollector.java | 4 ++++ .../spectator/aws/SpectatorServiceMetricCollector.java | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorMetricCollector.java b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorMetricCollector.java index 9550eed36..a2beadfbe 100644 --- a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorMetricCollector.java +++ b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorMetricCollector.java @@ -23,7 +23,11 @@ /** * A MetricCollector that captures SDK metrics. + * + * @deprecated Users should migrate to AWS SDK for Java V2. AWS will drop support + * for V1 after 2025. */ +@Deprecated public class SpectatorMetricCollector extends MetricCollector { private final RequestMetricCollector requestMetricCollector; private final ServiceMetricCollector serviceMetricCollector; diff --git a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorRequestMetricCollector.java b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorRequestMetricCollector.java index 09234786e..6deeaa433 100644 --- a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorRequestMetricCollector.java +++ b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorRequestMetricCollector.java @@ -37,7 +37,11 @@ /** * A {@link RequestMetricCollector} that captures request level metrics for AWS clients. + * + * @deprecated Users should migrate to AWS SDK for Java V2. AWS will drop support + * for V1 after 2025. */ +@Deprecated public class SpectatorRequestMetricCollector extends RequestMetricCollector { /** diff --git a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorServiceMetricCollector.java b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorServiceMetricCollector.java index 00af32387..33a3783ef 100644 --- a/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorServiceMetricCollector.java +++ b/spectator-ext-aws/src/main/java/com/netflix/spectator/aws/SpectatorServiceMetricCollector.java @@ -27,7 +27,11 @@ /** * A {@link ServiceMetricCollector} that captures the time it takes to get a connection * from the pool. + * + * @deprecated Users should migrate to AWS SDK for Java V2. AWS will drop support + * for V1 after 2025. */ +@Deprecated class SpectatorServiceMetricCollector extends ServiceMetricCollector { private final Timer clientGetConnectionTime;