dcapwell commented on code in PR #3486:
URL: https://github.com/apache/cassandra/pull/3486#discussion_r1725450613
##########
test/unit/accord/utils/Property.java:
##########
@@ -18,23 +18,25 @@
package accord.utils;
+import accord.utils.async.TimeoutUtils;
+
import java.time.Duration;
+import java.util.ArrayList;
import java.util.Arrays;
+import java.util.Collection;
+import java.util.List;
import java.util.Objects;
import java.util.concurrent.ExecutionException;
-import java.util.concurrent.ThreadLocalRandom;
-import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;
+import java.util.function.Consumer;
+import java.util.stream.Collectors;
import javax.annotation.Nullable;
-import org.apache.cassandra.transport.ProtocolException;
-import org.apache.cassandra.utils.concurrent.AsyncPromise;
-
public class Property
{
public static abstract class Common<T extends Common<T>>
{
- protected long seed = ThreadLocalRandom.current().nextLong();
Review Comment:
`ThreadLocalRandom` should be avoided at all costs... the seed isn't random
which means restarting the JVM yields the same seed... so you keep running the
same tests over and over and over again...
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]