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 WebRequestTrackingFilter uses ThreadLocal to store state. This state is not cleaned up in a finally-clause, but it's cleaned up on this line. That line is never reached if chain.doFilter throws an exception since the exception handling rethrows the exception.
By the way, wouldn't the rethrow make it impossible to correlate the exception with the request? Since no telemetry in sent with request information? How does that correlation work?
By the way2: It's good practice to have classes not marked with final and use protected for fields and methods when writing libraries. When bugs such as these occur, it is much easier for clients to deal with them. With the code as it stands now, I'm left with forking the project and releasing an in-house version with a fix, or copy all the code into my code base.
The text was updated successfully, but these errors were encountered:
The
WebRequestTrackingFilter
usesThreadLocal
to store state. This state is not cleaned up in afinally
-clause, but it's cleaned up on this line. That line is never reached ifchain.doFilter
throws an exception since the exception handling rethrows the exception.By the way, wouldn't the rethrow make it impossible to correlate the exception with the request? Since no telemetry in sent with request information? How does that correlation work?
By the way2: It's good practice to have classes not marked with
final
and useprotected
for fields and methods when writing libraries. When bugs such as these occur, it is much easier for clients to deal with them. With the code as it stands now, I'm left with forking the project and releasing an in-house version with a fix, or copy all the code into my code base.The text was updated successfully, but these errors were encountered: