Failed to capture traces if sentry-trace
header exists
#1099
Labels
Type: Bug
Something isn't working
sentry-trace
header exists
#1099
Platform:
IDE:
Build #IC-202.8194.7, built on November 24, 2020
Build system:
Android Gradle Plugin:
Sentry Android Gradle Plugin:
Proguard/R8:
Platform installed with:
The version of the SDK:
4.0.0-alpha.1
I have the following issue:
So if the
sentry-trace
header is exists it willstartTransaction
in this line https://github.com/getsentry/sentry-java/blob/main/sentry-spring/src/main/java/io/sentry/spring/tracing/SentryTracingFilter.java#L88.The transactionContext only set the parentSampled in https://github.com/getsentry/sentry-java/blob/main/sentry/src/main/java/io/sentry/TransactionContext.java#L42, but does not set the
sampled
(set to null) https://github.com/getsentry/sentry-java/blob/main/sentry/src/main/java/io/sentry/TransactionContext.java#L40This will lead to always skipping the capture process in https://github.com/getsentry/sentry-java/blob/main/sentry/src/main/java/io/sentry/Hub.java#L652-L658 because the
transaction.isSampled()
returns nullExpected result:
sentry-trace
header existsThe text was updated successfully, but these errors were encountered: