beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (BEAM-196) Pipeline options must be available Context in DoFn.startBundle
Date Wed, 08 Jun 2016 10:44:21 GMT


ASF GitHub Bot commented on BEAM-196:

GitHub user mxm opened a pull request:

    [BEAM-196] Additional fix to ensure the PipelineOptions are available in DoFns.

    Fixes a NullPointException if `PipelineOptions` are acceessed inside a DoFn and backs
it up with a test.

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

    $ git pull BEAM-196

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

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

    This closes #432
commit 05287c4ddcc38378e4e8cd921b6f6394e43eed75
Author: Maximilian Michels <>
Date:   2016-06-07T11:57:33Z

    [BEAM-196] fix NPE in ParDoWrapper

commit 595146d5759a6f631f057050cdbe71f9849035f9
Author: Maximilian Michels <>
Date:   2016-06-08T10:40:50Z

    [flink] improve lifecycle of ParDoBoundWrapper


> Pipeline options must be available Context in DoFn.startBundle
> --------------------------------------------------------------
>                 Key: BEAM-196
>                 URL:
>             Project: Beam
>          Issue Type: Bug
>          Components: runner-flink
>            Reporter: Mark Shields
>            Assignee: Maximilian Michels
>             Fix For: 0.1.0-incubating
> Our (not yet merged) Java Pubsub implementation has code like this in a DoFn:
>     @Override
>     public void startBundle(Context c) throws Exception {
>       Preconditions.checkState(pubsubClient == null);
>       pubsubClient = PubsubClient.newClient(transportType,
>           timestampLabel, idLabel, c.getPipelineOptions().as(PubsubOptions.class));
>       super.startBundle(c);
>     }
> This fails with NPE since the pipeline options are not conveyed via the context.

This message was sent by Atlassian JIRA

View raw message