Allow multiple input implementations in an aggregation function
@@ -97,10 +97,11 @@ public class AggregationFromAnnotationsParser
Method combineFunction = getCombineFunction(aggregationDefinition, stateClass);
Optional<Method> aggregationStateSerializerFactory = getAggregationStateSerializerFactory(aggregationDefinition, stateClass);
Method outputFunction = getOnlyElement(getOutputFunctions(aggregationDefinition, stateClass));
- Method inputFunction = getOnlyElement(getInputFunctions(aggregationDefinition, stateClass));
+ for (Method inputFunction : getInputFunctions(aggregationDefinition, stateClass)) {
AggregationImplementation implementation = parseImplementation(aggregationDefinition, header, stateClass, inputFunction, outputFunction, combineFunction, aggregationStateSerializerFactory);
implementationsBuilder.addImplementation(implementation);
}
+ }
ParametricImplementationsGroup<AggregationImplementation> implementations = implementationsBuilder.build();
return new ParametricAggregation(implementations.getSignature(), header, implementations);
