Class InPlaceMutableHashTable.ReduceFacade
java.lang.Object
org.apache.flink.runtime.operators.hash.InPlaceMutableHashTable.ReduceFacade
- Enclosing class:
- InPlaceMutableHashTable<T>
A facade for doing such operations on the hash table that are needed for a reduce operator
driver.
-
Constructor Summary
ConstructorsConstructorDescriptionReduceFacade(org.apache.flink.api.common.functions.ReduceFunction<T> reducer, org.apache.flink.util.Collector<T> outputCollector, boolean objectReuseEnabled) -
Method Summary
Modifier and TypeMethodDescriptionvoidemit()Emits all elements currently held by the table to the collector.voidEmits all elements currently held by the table to the collector, and resets the table.voidupdateTableEntryWithReduce(T record) Looks up the table entry that has the same key as the given record, and updates it by performing a reduce step.
-
Constructor Details
-
ReduceFacade
-
-
Method Details
-
updateTableEntryWithReduce
Looks up the table entry that has the same key as the given record, and updates it by performing a reduce step.- Parameters:
record- The record to update.- Throws:
Exception
-
emit
Emits all elements currently held by the table to the collector.- Throws:
IOException
-
emitAndReset
Emits all elements currently held by the table to the collector, and resets the table. The table will have the same number of buckets as before the reset, to avoid doing resizes again.- Throws:
IOException
-