Skip to content

Commit 2edb2f0

Browse files
authored
add a parallel variable with default config (#278)
1 parent 32f4aad commit 2edb2f0

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

sdk/src/main/java/software/amazon/lambda/durable/DurableContext.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -518,6 +518,15 @@ default <I, O> DurableFuture<MapResult<O>> mapAsync(
518518
<I, O> DurableFuture<MapResult<O>> mapAsync(
519519
String name, Collection<I> items, TypeToken<O> resultType, MapFunction<I, O> function, MapConfig config);
520520

521+
/**
522+
* Creates a {@link ParallelDurableFuture} for executing multiple branches concurrently with default config
523+
*
524+
* @return a new ParallelDurableFuture for registering and executing branches
525+
*/
526+
default ParallelDurableFuture parallel(String name) {
527+
return parallel(name, ParallelConfig.builder().build());
528+
}
529+
521530
/**
522531
* Creates a {@link ParallelDurableFuture} for executing multiple branches concurrently.
523532
*

0 commit comments

Comments
 (0)