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

[#24339] Make Slices use iterable coder instead of custom coder. #24346

Merged
merged 8 commits into from
Nov 29, 2022

Conversation

lostluck
Copy link
Contributor

@lostluck lostluck commented Nov 24, 2022

Changes the default encoding of Go slices to use the beam iterable coder format.

Technically this is the same format as before, but without a length prefix.

Changing coder implementations are generally a breaking change, however this only applies to streaming updates or when trying to re-use the internal pipeline coders. The benefit of cross language compatibility longer term, in a format expected by go users, is perceived to be a larger benefit.

Fixes #24339.

Additionally:

  • Changes to make exec structure debugging more consistent and useful.

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Choose reviewer(s) 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.

See the Contributor Guide for more tips on how to make review process smoother.

To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests
Go tests

See CI.md for more information about GitHub Actions CI.

@github-actions github-actions bot added the go label Nov 24, 2022
@lostluck lostluck mentioned this pull request Nov 24, 2022
4 tasks
@codecov
Copy link

codecov bot commented Nov 24, 2022

Codecov Report

Merging #24346 (e380bbf) into master (d2211bd) will increase coverage by 0.01%.
The diff coverage is 70.37%.

❗ Current head e380bbf differs from pull request most recent head 13404d2. Consider uploading reports for the commit 13404d2 to get more accurate results

@@            Coverage Diff             @@
##           master   #24346      +/-   ##
==========================================
+ Coverage   73.34%   73.36%   +0.01%     
==========================================
  Files         718      718              
  Lines       96966    97034      +68     
==========================================
+ Hits        71120    71187      +67     
+ Misses      24515    24503      -12     
- Partials     1331     1344      +13     
Flag Coverage Δ
go 51.55% <70.37%> (+0.10%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
sdks/go/pkg/beam/core/runtime/exec/datasource.go 62.00% <0.00%> (ø)
sdks/go/pkg/beam/core/runtime/graphx/dataflow.go 51.71% <50.00%> (-2.23%) ⬇️
sdks/go/pkg/beam/core/typex/fulltype.go 48.82% <54.54%> (+7.32%) ⬆️
sdks/go/pkg/beam/coder.go 56.33% <64.28%> (+1.38%) ⬆️
sdks/go/pkg/beam/core/runtime/graphx/coder.go 52.23% <80.00%> (+0.32%) ⬆️
sdks/go/pkg/beam/core/runtime/exec/translate.go 17.46% <85.71%> (+4.73%) ⬆️
sdks/go/pkg/beam/core/runtime/exec/pardo.go 59.60% <100.00%> (ø)
... and 1 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@github-actions
Copy link
Contributor

Assigning reviewers. If you would like to opt out of this review, comment assign to next reviewer:

R: @jrmccluskey for label go.

Available commands:

  • stop reviewer notifications - opt out of the automated review tooling
  • remind me after tests pass - tag the comment author after tests pass
  • waiting on author - shift the attention set back to the author (any comment or push by the author will return the attention set to the reviewers)

The PR bot will only process comments in the main thread (not review comments).

@lostluck
Copy link
Contributor Author

Run Go PostCommit

@lostluck
Copy link
Contributor Author

R: @riteshghorse

This should unblock RunInference.

@github-actions
Copy link
Contributor

Stopping reviewer notifications for this pull request: review requested by someone other than the bot, ceding control

@lostluck
Copy link
Contributor Author

lostluck commented Nov 28, 2022

Looks like not having a comprehensive test runner for all the different versions and variants of what runners can do strikes again! Should be simple enough though.

Specifically, Dataflow appears to turn something into the "state backed" coder, and I'm missing the appropriate handling for it in some instances.

@lostluck
Copy link
Contributor Author

Run Go PostCommit

@lostluck
Copy link
Contributor Author

Run Go Flink ValidatesRunner

@lostluck
Copy link
Contributor Author

Run Go Flink ValidatesRunner

@lostluck
Copy link
Contributor Author

Run Go PostCommit

Copy link
Contributor

@riteshghorse riteshghorse left a comment

Choose a reason for hiding this comment

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

minor nits but LGTM. Thanks for unblocking!

sdks/go/pkg/beam/core/runtime/exec/datasource.go Outdated Show resolved Hide resolved
sdks/go/pkg/beam/core/runtime/exec/translate.go Outdated Show resolved Hide resolved
@riteshghorse riteshghorse merged commit 166b881 into apache:master Nov 29, 2022
@lostluck
Copy link
Contributor Author

Thanks for the review!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[New Feature][Go SDK]: Support user use of the Beam Iterable Coder.
2 participants