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

ContinueFromHeaders should handle all combinations of sentry-trace/baggage properly #533

Open
tonyo opened this issue Jan 18, 2023 · 0 comments

Comments

@tonyo
Copy link
Member

tonyo commented Jan 18, 2023

At the moment ContinueFromHeaders function doesn't handle a case properly when sentry-trace is empty, and baggage is populated with some Sentry data.
In this case, the created span should have an empty unfrozen Dynamic Sampling Context, because the current SDK will essentially become the head SDK.

Extracted from #532:

	        // TODO(anton): we should handle this case properly
		// {
		// 	// No sentry-trace, but baggage with Sentry values => this is a head SDK, so the DSC
		// 	// should be empty and unfrozen.
		// 	traceStr:   "",
		// 	baggageStr: "sentry-trace_id=d49d9bf66f13450b81f65bc51cf49c03,sentry-public_key=public,sentry-sample_rate=1",
		// 	wantSpan: Span{
		// 		isTransaction: true,
		// 		dynamicSamplingContext: DynamicSamplingContext{
		// 			Frozen: false,
		// 		},
		// 	},
		// },
@tonyo tonyo self-assigned this Jan 18, 2023
@tonyo tonyo removed their assignment Dec 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant