Class ActorFutureCollector<V>
java.lang.Object
io.camunda.zeebe.scheduler.future.ActorFutureCollector<V>
- Type Parameters:
V- type of the value of each future
- All Implemented Interfaces:
Collector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
public final class ActorFutureCollector<V>
extends Object
implements Collector<ActorFuture<V>,List<ActorFuture<V>>,ActorFuture<List<V>>>
Aggregates a number of
ActorFuture objects into a single one. The aggregated future is
completed when all individual futures have completed. If all futures complete with a value, the
aggregated future returns the ordered list of said values. If one or more complete exceptionally,
the aggregated future will complete exceptionally. The exception will have the exceptions of the
individual futures aas suppressed exceptions. If exceptions occur, this does not interrupt the
individual futures.
var aggregated = of(future1, future2).stream().collect(new ActorFutureCollectorinvalid input: '<'>(concurrencyControl));
-
Nested Class Summary
Nested classes/interfaces inherited from interface java.util.stream.Collector
Collector.Characteristics -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncombiner()Function<List<ActorFuture<V>>, ActorFuture<List<V>>> finisher()Supplier<List<ActorFuture<V>>> supplier()
-
Constructor Details
-
ActorFutureCollector
-
-
Method Details
-
supplier
- Specified by:
supplierin interfaceCollector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
-
accumulator
- Specified by:
accumulatorin interfaceCollector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
-
combiner
- Specified by:
combinerin interfaceCollector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
-
finisher
- Specified by:
finisherin interfaceCollector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
-
characteristics
- Specified by:
characteristicsin interfaceCollector<ActorFuture<V>,List<ActorFuture<V>>, ActorFuture<List<V>>>
-