Hi Soheil,
Yes, reduce function doesn't allow this. A ReduceFunction specifies how two
elements from the input are combined to produce an output element of the
same type.
You can use AggregateFunction or FoldFunction. More details here[1].
Best, Hequn
[1]
https://ci.apache.org/projects/flink/fli
Hi, I have a keyed datastream in the type of Tuple2. I want
to reduce it and merge all of the byte[] for a key. (the first filed (Long)
is the key). So I need reduce function return the type Tuple2>, but reduce function didn't allow that! How can I do
such job in Flink?