Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BEAM-196] Pipeline options must be available Context in DoFn.startBundle #200

Merged
merged 2 commits into from
Apr 19, 2016

Conversation

mxm
Copy link
Contributor

@mxm mxm commented Apr 18, 2016

This gets rid of the custom Java serialization code by defaulting to serialization of the PipelineOptions to a byte array. So far, this has been proven the most hassle-free method for the Flink Runner. For code reuse and avoiding multiple deserialization of the byte array, the SerializedPipelineOptions class has been introduced.

The changes also make the options accessible in the context of the DoFn function.

assertNotNull(deserializedOptions);
assertEquals(deserializedOptions, serializedOptions.getPipelineOptions());
assertEquals(deserializedOptions, serializedOptions.getPipelineOptions());
assertEquals(deserializedOptions, serializedOptions.getPipelineOptions());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could use Hamcrest Matchers.sameInstance. Not tested, but:

assertThat(serializedOptions.getPipelineOptions(), Matchers.sameInstance(deserializedOptions));

@dhalperi
Copy link
Contributor

LGTM

@dhalperi
Copy link
Contributor

R: @dhalperi

Since you didn't pick someone specific ;)

@mxm
Copy link
Contributor Author

mxm commented Apr 19, 2016

Thanks for the review @dhalperi!

@asfgit asfgit merged commit 43b5ec7 into apache:master Apr 19, 2016
asfgit pushed a commit that referenced this pull request Apr 19, 2016
@mxm mxm deleted the BEAM-196 branch April 19, 2016 07:49
swegner pushed a commit to swegner/beam that referenced this pull request Apr 22, 2016
Implement BigQueryIO.Write as a sink
iemejia pushed a commit to iemejia/beam that referenced this pull request Jan 12, 2018
mareksimunek pushed a commit to mareksimunek/beam that referenced this pull request May 9, 2018
[euphoria-build] remove unused protobuf plugin
Abacn pushed a commit to Abacn/beam that referenced this pull request Jan 31, 2023
…gMessageErrorsAsCsv

PiperOrigin-RevId: 355894522
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants