seungjin-an opened a new pull request, #24276:
URL: https://github.com/apache/beam/pull/24276
Samza runner support for same stateId with multiple ParDos
(1) Do not touch existing RocksDB Store Id with stateId used only by one
ParDo
(2) Introduce new mapping of user-provided stateIds to store ID for those
stateIds used in multiple ParDos
// stateId used in a single ParDo continue to use the same stateId as storeId
.apply("First stateful ParDo", ParDo.of(fn));
→ “foo"
// stateId used in multiple ParDos use a new mapping to store Id with
PTransform name
.apply("Second stateful ParDo", ParDo.of(fn2));
→ “foo-Second_stateful_ParDo”
- ConfigContext/TranslationContext keeps track of all stateIds and their
PTransform names used in all PTransform nodes as we traverse them
topologically.
- Can't find out which stateId is used in multiple ParDo(s) until all
PTransform nodes are traversed. Thus, after traversal is complete, re-write
store related configs for stateId that was first added with original mapping
(eg. rewrite from "foo" --> "foo-First_stateful_ParDo")
(3) Re-enable ParDoTest in :runners:samza build.gradle
------------------------
Thank you for your contribution! Follow this checklist to help us
incorporate your contribution quickly and easily:
- [ ] [**Choose
reviewer(s)**](https://beam.apache.org/contribute/#make-your-change) and
mention them in a comment (`R: @username`).
- [ ] Mention the appropriate issue in your description (for example:
`addresses #123`), if applicable. This will automatically add a link to the
pull request in the issue. If you would like the issue to automatically close
on merging the pull request, comment `fixes #<ISSUE NUMBER>` instead.
- [ ] Update `CHANGES.md` with noteworthy changes.
- [ ] If this contribution is large, please file an Apache [Individual
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
See the [Contributor Guide](https://beam.apache.org/contribute) for more
tips on [how to make review process
smoother](https://beam.apache.org/contribute/get-started-contributing/#make-the-reviewers-job-easier).
To check the build health, please visit
[https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md](https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md)
GitHub Actions Tests Status (on master branch)
------------------------------------------------------------------------------------------------
[](https://github.com/apache/beam/actions?query=workflow%3A%22Build+python+source+distribution+and+wheels%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Python+Tests%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Java+Tests%22+branch%3Amaster+event%3Aschedule)
[](https://github.com/apache/beam/actions?query=workflow%3A%22Go+tests%22+branch%3Amaster+event%3Aschedule)
See [CI.md](https://github.com/apache/beam/blob/master/CI.md) for more
information about GitHub Actions CI.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]