Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[aws] default to use Semantic Convention 1.28 and remove option Legacy #2437

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#nullable enable
OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion.Legacy = -1 -> OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion.Latest = 0 -> OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion.V1_29_0 = 2 -> OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion.V1_28_0 = 1 -> OpenTelemetry.Instrumentation.AWS.SemanticConventionVersion
Expand Down
2 changes: 2 additions & 0 deletions src/OpenTelemetry.Instrumentation.AWS/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Unreleased

* BREAKING: Change default Semantic Convention to 1.28

## 1.10.0-beta.3

Released 2024-Dec-20
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#nullable enable
OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion.Legacy = -1 -> OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion.Latest = 0 -> OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion
OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion.V1_29_0 = 2 -> OpenTelemetry.Instrumentation.AWSLambda.SemanticConventionVersion
Expand Down
2 changes: 2 additions & 0 deletions src/OpenTelemetry.Instrumentation.AWSLambda/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Unreleased

* BREAKING: Change default Semantic Convention to 1.28

## 1.10.0-beta.3

Released 2024-Dec-20
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
OpenTelemetry.Resources.AWS.SemanticConventionVersion
OpenTelemetry.Resources.AWS.SemanticConventionVersion.Legacy = -1 -> OpenTelemetry.Resources.AWS.SemanticConventionVersion
OpenTelemetry.Resources.AWS.SemanticConventionVersion.Latest = 0 -> OpenTelemetry.Resources.AWS.SemanticConventionVersion
OpenTelemetry.Resources.AWS.SemanticConventionVersion.V1_29_0 = 2 -> OpenTelemetry.Resources.AWS.SemanticConventionVersion
OpenTelemetry.Resources.AWS.SemanticConventionVersion.V1_28_0 = 1 -> OpenTelemetry.Resources.AWS.SemanticConventionVersion
Expand Down
2 changes: 2 additions & 0 deletions src/OpenTelemetry.Resources.AWS/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Unreleased

* BREAKING: Change default Semantic Convention to 1.28

* Introduce `AWSResourceBuilderOptions.SemanticConventionVersion` which
provides a mechanism for developers to opt-in to newer versions of the
of the Open Telemetry Semantic Conventions.
Expand Down
11 changes: 1 addition & 10 deletions src/Shared/AWS/AWSSemanticConventions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,6 @@
#pragma warning disable SA1201
#pragma warning disable SA1623

// disable obsolete warning - remove in RC
#pragma warning disable CS0618

namespace OpenTelemetry.AWS;

/// <summary>
Expand Down Expand Up @@ -69,10 +66,7 @@ internal partial class AWSSemanticConventions
/// Per SemanticConventionVersion, default should stay as
/// <see cref="SemanticConventionVersion.V1_28_0"/> until next major version bump.
/// </remarks>
internal const SemanticConventionVersion DefaultSemanticConventionVersion = SemanticConventionVersion.Legacy;

// RC Release: change to
//SemanticConventionVersion.V1_28_0;
internal const SemanticConventionVersion DefaultSemanticConventionVersion = SemanticConventionVersion.V1_28_0;

private readonly SemanticConventionVersion semanticConventionVersion;

Expand Down Expand Up @@ -494,9 +488,6 @@ private AWSSemanticConventionsBase GetSemanticConventionVersion()
case SemanticConventionVersion.V1_28_0:
return new AWSSemanticConventions_V1_28_0();

case SemanticConventionVersion.Legacy:
return new AWSSemanticConventionsLegacy();

default:
throw new InvalidEnumArgumentException(
argumentName: nameof(SemanticConventionVersion),
Expand Down
12 changes: 0 additions & 12 deletions src/Shared/AWS/SemanticConventionVersion.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,18 +73,6 @@ public enum SemanticConventionVersion
/// </summary>
Latest = 0,

/// <summary>
/// Represents the mixture of Semantic Conventions used in OpenTelemetry.*.AWS libraries
/// in 1.10.0-beta.x.
/// <para />
/// This allows users to upgrade to the latest beta nuget package without experiencing a change in
/// Semantic Convention output. Then there is an opportunity for users to trial <see cref="V1_28_0"/>.
/// <para />
/// This option will be REMOVED in the next Release Candidate.
/// </summary>
[Obsolete("This will be removed in the 1.10.0-RC", error: false)]
Legacy = -1,

/// <summary>
/// Pin to the specific state of all Semantic Conventions as of the 1.28.0
/// release. See:
Expand Down