You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2019/07/11 18:03:10 UTC

[GitHub] [incubator-pinot] jackjlli commented on a change in pull request #4368: 3891: Check for validity of segment start/end time during segment generation

jackjlli commented on a change in pull request #4368: 3891: Check for validity of segment start/end time during segment generation
URL: https://github.com/apache/incubator-pinot/pull/4368#discussion_r302671587
 
 

 ##########
 File path: pinot-core/src/test/java/org/apache/pinot/core/data/readers/PinotSegmentUtil.java
 ##########
 @@ -47,16 +52,16 @@ private PinotSegmentUtil() {
 
   public static List<GenericRow> createTestData(Schema schema, int numRows) {
     List<GenericRow> rows = new ArrayList<>();
-    final Random random = new Random();
+    final ThreadLocalRandom random = ThreadLocalRandom.current();
 
 Review comment:
   What's the pro to use `ThreadLocalRandom` instead of `Random`?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org