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

Rename Baggage Header name to baggage #2003

Merged
Merged
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
4 changes: 4 additions & 0 deletions src/OpenTelemetry.Api/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ please check the latest changes

## Unreleased

* `BaggagePropagator` now uses `baggage` as the header name instead of `Baggage`
to `Extract` from and `Inject` to `carrier`
([#2003](https://github.com/open-telemetry/opentelemetry-dotnet/pull/2003))

## 1.1.0-beta1

Released 2021-Mar-19
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ namespace OpenTelemetry.Context.Propagation
/// </summary>
public class BaggagePropagator : TextMapPropagator
{
internal const string BaggageHeaderName = "Baggage";
internal const string BaggageHeaderName = "baggage";

private const int MaxBaggageLength = 8192;
private const int MaxBaggageItems = 180;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ public async Task HttpClientInstrumentationContextPropagation()

Assert.True(request.Headers.TryGetValues("traceparent", out var traceparents));
Assert.True(request.Headers.TryGetValues("tracestate", out var tracestates));
Assert.True(request.Headers.TryGetValues("Baggage", out var baggages));
Assert.True(request.Headers.TryGetValues("baggage", out var baggages));
Assert.Single(traceparents);
Assert.Single(tracestates);
Assert.Single(baggages);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -816,7 +816,7 @@ private static void ActivityEnrichment(Activity activity, string method, object

private static void ValidateBaggage(HttpWebRequest request)
{
string[] baggage = request.Headers["Baggage"].Split(',');
string[] baggage = request.Headers["baggage"].Split(',');

Assert.Equal(3, baggage.Length);
Assert.Contains("key=value", baggage);
Expand Down