dcapwell commented on code in PR #3835:
URL: https://github.com/apache/cassandra/pull/3835#discussion_r1931180773
##########
test/unit/org/apache/cassandra/utils/CassandraGenerators.java:
##########
@@ -650,13 +1024,32 @@ public static Gen<IPartitioner> partitioners()
.flatMap(SupportedPartitioners::partitioner);
}
+
public static Gen<IPartitioner> nonLocalPartitioners()
{
return SourceDSL.arbitrary().enumValues(SupportedPartitioners.class)
.assuming(p -> p != SupportedPartitioners.Local)
.flatMap(SupportedPartitioners::partitioner);
}
+ /**
+ * For {@link LocalPartitioner} it can have a very complex type which can
lead to generating data larger than
+ * allowed in a primary key. If a test needs to filter out those cases,
can just
+ * {@code .map(CassandraGenerators::simplify)} to resolve.
+ */
+ public static IPartitioner simplify(IPartitioner partitioner)
Review Comment:
in a follow up patch ill prob remove this... `LocalPartitioner` has caused
flakyness for several tests in cep-15-accord so plan to refactor that logic to
be less problematic, which lets us drop this function... keeping for now just
to be in-sync
--
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]