snazy opened a new issue, #463:
URL: https://github.com/apache/polaris/issues/463

   ### Is this a possible security vulnerability?
   
   - [X] This is NOT a possible security vulnerability
   
   ### Describe the bug
   
   While `[Inheritable]ThreadLocal`s are relatively easy to start with to pass 
along request related information, `ThreadLocal`s come with a non-negligible 
cost and maintenance burden:
   
   * TLs can cause very hard to detect memory leaks as objects (and classes!) 
are (often permanently) attached to a thread.
   * TLs and their usage are hard to test
   * (The use of) TLs can accidentally share data across requests
   * Use of TLs becomes complex and hard to reason about
   
   The proper way of sharing _request_ related information is to use CDI's 
`@RequestScoped` beans.
   
   ### To Reproduce
   
   _No response_
   
   ### Actual Behavior
   
   _No response_
   
   ### Expected Behavior
   
   _No response_
   
   ### Additional context
   
   _No response_
   
   ### System information
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to