[BEAM-115] Runner API Translations for StateSpec and TimerSpec#3233
Merged
Conversation
tgroh
approved these changes
May 26, 2017
| equalTo(protoComponents.getPcollectionsOrThrow(mainInputId))); | ||
| } | ||
|
|
||
| @Test |
Member
There was a problem hiding this comment.
These tests are going to be run n times because the test as a whole is parameterized.
Member
Author
There was a problem hiding this comment.
Yea I'll probably move the parameterized bits into a sub-suite.
| return builder.build(); | ||
| } | ||
|
|
||
| private static Object getFieldOrCrash(Field field, Object target) { |
Member
There was a problem hiding this comment.
I'd prefer something that hides the need for a cast (e.g. getStateFieldOrCrash(Field, DoFn))
This is different than a StateBinder: for a binder, the id is needed and the StateSpec controls the return type. For case dispatch, the dispatcher controls the type and it should just be reading the spec, which does not require the id. Eventually, StateBinder could be removed in favor of StateSpec.Cases<Function<String, StateT>>.
5aa01d6 to
f804f05
Compare
f804f05 to
39220db
Compare
asfgit
pushed a commit
that referenced
this pull request
May 26, 2017
…nd TimerSpec Implement TimerSpec and StateSpec translation Make Java serialized CombineFn URN public Add case dispatch to StateSpec Flesh out TimerSpec and StateSpec in Runner API Allow translation to throw IOException Mark CombineFnWithContext StateSpecs internal
|
Changes Unknown when pulling 39220db on kennknowles:translate-StateSpec into ** on apache:master**. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Be sure to do all of the following to help us incorporate your contribution
quickly and easily:
[BEAM-<Jira issue #>] Description of pull requestmvn clean verify.<Jira issue #>in the title with the actual Jira issuenumber, if there is one.
Individual Contributor License Agreement.
R: @tgroh
The awkward bit is that a combining
StateSpecis statically typed to take aCombineFn. So when we get around to issuing Fn State API requests, we'll need to work around that.