You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The TracingRequestHandler in brave-instrumentation/aws-java-sdk-core can throw NPE due to an application span not being present in both the beforeAttempt and afterAttempt callback.
The root cause here is the s3 client executes a stealth HEAD request for many of the operations like CreateBucket, doesBucketExistV2 to do some preliminary checking and caching. Unfortunately, these HEAD requests do not invoke beforeExecution so an application span is never created for them, but they do invoke beforeAttempt.
This means the overall aws-sdk span isn't available and results in the NPE.
A couple of options:
Capture the head request and correctly map it to its parent. I'm not sure this is possible with what the callback provides.
ignore requests that don't have the span from beforeExecution
The text was updated successfully, but these errors were encountered:
* Added null checks for the application spans due to internal requests made when s3 client is configured with enableForceGlobalBucketAccess()
* PR feedback: Prefer early return on null checks; Simplify testing with MockWebServer
The TracingRequestHandler in brave-instrumentation/aws-java-sdk-core can throw NPE due to an application span not being present in both the
beforeAttempt
andafterAttempt
callback.The root cause here is the s3 client executes a stealth HEAD request for many of the operations like
CreateBucket
,doesBucketExistV2
to do some preliminary checking and caching. Unfortunately, these HEAD requests do not invokebeforeExecution
so an application span is never created for them, but they do invokebeforeAttempt
.This means the overall
aws-sdk
span isn't available and results in the NPE.A couple of options:
beforeExecution
The text was updated successfully, but these errors were encountered: