ctubbsii commented on pull request #2339:
URL: https://github.com/apache/accumulo/pull/2339#issuecomment-957998895


   > LGTM - seeing all of the places where we create an instance of 
SecureRandom - would there be significant benefit if a ServerContext created an 
instance an then it was reused anywhere that a random number was needed and 
context was available - possibly as a follow on PR?
   
   So, I thought about that... but, there's a risk of having things block if 
the Java security provider for SecureRandom isn't thread safe. So, I chose to 
limit the amount of sharing of these instances. So, if the implementation is 
thread-safe, there's just a few extra objects hanging around in the JVM, but if 
it's not thread-safe, the scope of any potential contention is limited.


-- 
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