flink-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vyacheslav Zholudev <vyacheslav.zholu...@gmail.com>
Subject Re: [stratosphere-dev] Grouping by a tuple
Date Thu, 12 Jun 2014 07:46:14 GMT
Hi Robert,

thanks, I will post my future questions to that list.

Regarding your question: When using the Tuples, you don't need to specify a 
> keySelector. It is sufficient to specify the ID(s) of the keys: 
> http://stratosphere-javadocs.github.io/eu/stratosphere/api/java/DataSet.html#groupBy(int..
> .)
> So you should be able to do a ".groupBy(0,3,4)"
Actually my question is about the situation when I don't have tuples. 
Assume I have a DataSet<UserData> ds and I want to invoke ds.groupBy(/* 
grouping by <userId, sessionId, dayOfTheYear> */), the ideal choice would 
be to return a comparable tuple from the KeySelector.
On the side note, would it be possible to generate the clone method for the 
tuples? Yesterday I was copying a Tuple13 in a groupReduce function by hand 
and it was a pretty long line of code :)


  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message