[ https://issues.apache.org/jira/browse/FLINK-2184?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15972557#comment-15972557 ]
ASF GitHub Bot commented on FLINK-2184: --------------------------------------- Github user aljoscha commented on the issue: https://github.com/apache/flink/pull/3110 Thanks for notifying @fhueske! And sorry for not noticing this earlier and jumping on so late. I think this part of the API is already to bloated and (at the same time) not powerful enough. These functions don't allow having multiple "aggregations" in one operation, i.e. you cannot do `inputStream.keyBy(...).min(1).andMax(2).andSum(3)` (not actual API). I think in the long run we should remove this part of the API because the Table API is a nicer way of expressing simple aggregations. What do you think? > Cannot get last element with maxBy/minBy > ---------------------------------------- > > Key: FLINK-2184 > URL: https://issues.apache.org/jira/browse/FLINK-2184 > Project: Flink > Issue Type: Improvement > Components: DataStream API, Scala API > Reporter: Gábor Hermann > Priority: Minor > > In the streaming Scala API there is no method > {{maxBy(int positionToMaxBy, boolean first)}} > nor > {{minBy(int positionToMinBy, boolean first)}} > like in the Java API, where _first_ set to {{true}} indicates that the latest > found element will return. > These methods should be added to the Scala API too, in order to be consistent. -- This message was sent by Atlassian JIRA (v6.3.15#6346)