unknowntpo commented on code in PR #22371:
URL: https://github.com/apache/kafka/pull/22371#discussion_r3389028422
##########
storage/src/test/java/org/apache/kafka/tiered/storage/TieredStorageTestBuilder.java:
##########
@@ -318,6 +322,40 @@ public List<TieredStorageTestAction> complete() {
return actions;
}
+ /**
+ * Builds an executable test plan from the actions described so far.
+ */
+ public TieredStorageTestPlan build() {
+ return new TieredStorageTestPlan(complete());
+ }
+
+ public static final class TieredStorageTestPlan {
+
+ private final List<TieredStorageTestAction> actions;
+
+ private TieredStorageTestPlan(List<TieredStorageTestAction> actions) {
+ this.actions = List.copyOf(actions);
+ }
+
+ public void execute(ClusterInstance clusterInstance, GroupProtocol
groupProtocol) throws Exception {
+ Map<String, Object> consumerProps = new HashMap<>();
+ consumerProps.put(ConsumerConfig.GROUP_PROTOCOL_CONFIG,
groupProtocol.name().toLowerCase(Locale.ROOT));
+ execute(clusterInstance, consumerProps);
Review Comment:
Thanks, simplified it as suggested.
--
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]