markusthoemmes commented on issue #2747: Use non-blocking UUID generation in controller URL: https://github.com/apache/incubator-openwhisk/issues/2747#issuecomment-331089914 @dgrove-oss fair point, here are a few profiling results. I think I arrived at a solution for us: ### Testcode ```scala def main(args: Array[String]): Unit = { (1 to 100000000).par.foreach { _ => val uuid = randomUUID() } } ``` Parallel generation of 100000000 random UUIDs. ### Baseline: `java.util.UUID.randomUUID()`  (It goes on until about 2:50 minutes) ### Switching from `/dev/random` (blocking) to `/dev/urandom` (non-blocking)  Much better already, but still a lot of thread contention. ### Switching to `ThreadLocal[SecureRandom]`  There we go! So it looks like the innerts of `SecureRandom` do not contain any more contention which is great. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected]
With regards, Apache Git Services
