You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/01/25 16:28:40 UTC

[jira] [Commented] (FLINK-3198) Rename Grouping.getDataSet() method and add JavaDocs

    [ https://issues.apache.org/jira/browse/FLINK-3198?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15115389#comment-15115389 ] 

ASF GitHub Bot commented on FLINK-3198:
---------------------------------------

GitHub user kl0u opened a pull request:

    https://github.com/apache/flink/pull/1548

    FLINK-3198: Renames and documents the getDataSet() method in Grouping.

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/kl0u/flink groupBy_renaming

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/1548.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1548
    
----
commit 130fc0c27c1582db4b9528e1ee7818de8d48bef3
Author: Kostas Kloudas <kk...@gmail.com>
Date:   2016-01-25T15:07:39Z

    FLINK-3198: Renames and documents better the use of the getDataSet() in Grouping.

----


> Rename Grouping.getDataSet() method and add JavaDocs
> ----------------------------------------------------
>
>                 Key: FLINK-3198
>                 URL: https://issues.apache.org/jira/browse/FLINK-3198
>             Project: Flink
>          Issue Type: Improvement
>          Components: DataSet API
>    Affects Versions: 1.0.0, 0.10.1
>            Reporter: Fabian Hueske
>            Assignee: Kostas
>             Fix For: 1.0.0, 0.10.2
>
>
> The {{getDataSet()}} method of {{Grouping}} is public and visible to users. It returns the input of the grouping operation which can cause confusion. If this function is used in a regular DataSet program like this
> {code}
> DataSet<X> notGrouped = input.groupBy().getDataSet();
> DataSet<Y> allReduced = notGrouped.reduce()
> {code}
> the previous {{groupBy()}} call is basically discarded and an AllReduce is applied instead of a grouped Reduce.
> Since this method is not meant to be part of the public API we should help users to avoid this method. In the current API, we cannot easily change the visibility of the method without package restructuring or adding additional classes (and hence breaking binary compatibility).
> Instead I proprose to rename the method to something like {{getInputDataSet()}} or {{getGroupingInput()}} and add descriptive JavaDocs.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)