IN- Type of the elements that this function processes.
OUT- The type of the elements returned by the user-defined function.
@Public public abstract class RichGroupReduceFunction<IN,OUT> extends AbstractRichFunction implements GroupReduceFunction<IN,OUT>
GroupReduceFunction. As a
RichFunction, it gives access to the
RuntimeContextand provides setup and teardown methods:
Partial computation can significantly improve the performance of a
RichGroupReduceFunction. This technique is also known as applying a Combiner. Implement the
GroupCombineFunction interface to enable partial computation, i.e., a combiner for this
|Constructor and Description|
|Modifier and Type||Method and Description|
The reduce method.
close, getIterationRuntimeContext, getRuntimeContext, open, setRuntimeContext
values- All records that belong to the given input key.
out- The collector to hand results to.
Exception- This method may throw exceptions. Throwing an exception will cause the operation to fail and may trigger recovery.
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.