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

ASF GitHub Bot commented on BEAM-2686:
--------------------------------------

GitHub user jkff opened a pull request:

    https://github.com/apache/beam/pull/3649

    [BEAM-2686] Towards deprecating PCollection.setCoder()

    https://issues.apache.org/jira/browse/BEAM-2686
    
    - Renames Source.getDefaultOutputCoder to Source.getOutputCoder (in a 
compatible way), to avoid the implication that it is optional: it is not 
optional.
    - Requires specifying a Coder on PCollection.createPrimitiveOutputInternal: 
as of this PR it can still be null (in which case coder will stay unset), but 
eventually it won't be
    - Removes all overrides of PTransform.getDefaultOutputCoder and deprecates 
it: instead, PTransform's should explicitly .setCoder() on their output 
collection
    
    This PR is 3 boring, almost mechanical commits, each of which is large but 
should be individually easy to review.
    
    The next step (in a separate PR) will be getting rid of .setCoder() calls 
in the SDK. Nearly all such calls are on results of ParDo.of() and 
MapElements.via() and such - I'll need to add optional .withOutputCoder() 
parameters to those transforms.
    
    R: @robertwb 
    CC: @kennknowles 

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

    $ git pull https://github.com/jkff/incubator-beam set-coder

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

    https://github.com/apache/beam/pull/3649.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 #3649
    
----
commit c71762662812bb9b02b747790280c5d0a542b8e7
Author: Eugene Kirpichov <[email protected]>
Date:   2017-07-26T23:05:27Z

    Makes all Source classes override getOutputCoder instead of 
getDefaultOutputCoder

commit 7bb48421f739eef4ebca0faedae2b8af69cae567
Author: Eugene Kirpichov <[email protected]>
Date:   2017-07-27T00:14:58Z

    Requires specifying a Coder on PCollection.createPrimitiveOutputInternal
    
    The coder can still be null, in which case it is left unspecified.

commit 3653e56b885eeccf9d749d7d5b32969e9af5e043
Author: Eugene Kirpichov <[email protected]>
Date:   2017-07-26T23:33:36Z

    Removes all overrides of PTransform.getDefaultOutputCoder and deprecates it

----


> PTransform's should always set a Coder on their output PCollections
> -------------------------------------------------------------------
>
>                 Key: BEAM-2686
>                 URL: https://issues.apache.org/jira/browse/BEAM-2686
>             Project: Beam
>          Issue Type: Bug
>          Components: sdk-java-core
>            Reporter: Eugene Kirpichov
>            Assignee: Eugene Kirpichov
>
> See discussion on 
> https://lists.apache.org/thread.html/1dde0b5a93c2983cbab5f68ce7c74580102f5bb2baaa816585d7eabb@%3Cdev.beam.apache.org%3E



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to