fix randombug

This commit is contained in:
Looly 2020-08-07 16:29:34 +08:00
parent ec8926745d
commit b2dd13023f
2 changed files with 6 additions and 0 deletions

View File

@ -20,6 +20,7 @@
* 【core 】 修复NamedSql多个连续变量出现替换问题
* 【core 】 修复Bean重名字段大小写区别获取数据出错的问题issue#I1QBQ4@Gitee
* 【http 】 修复SimpleServer响应头无效问题issue#1006@Github
* 【core 】 修复ThreadLocalRandom共享seed导致获取随机数一样的问题pr#151@Gitee
-------------------------------------------------------------------------------------------------------------

View File

@ -47,6 +47,11 @@ public class RandomUtil {
* 获取随机数生成器对象<br>
* ThreadLocalRandom是JDK 7之后提供并发产生随机数能够解决多个线程发生的竞争争夺
*
* <p>
* 注意此方法返回的{@link ThreadLocalRandom}不可以在多线程环境下共享对象否则有重复随机数问题
* https://www.jianshu.com/p/89dfe990295c
* </p>
*
* @return {@link ThreadLocalRandom}
* @since 3.1.2
*/