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

Add Single.zipWith and Single.zip operators #1431

Merged
merged 5 commits into from
Mar 17, 2021

Conversation

Scottmitch
Copy link
Member

Motivation:
Executing multiple async operations in parallel and combining them in a
type safe way is a common use case, and referred to as zip [1]. We do
not support a zip operator which requires a careful sequence of
operators to replicate.

[1] http://reactivex.io/documentation/operators/zip.html

Modifications:

  • Add Single.zipWith
  • Add Single.zip overload for 3, 4, and varargs amount of Singles

Result:
Single.zip and Single.zipWith operators exist.

Copy link
Contributor

@bondolo bondolo left a comment

Choose a reason for hiding this comment

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

That came together pretty quickly!

@Scottmitch
Copy link
Member Author

Scottmitch commented Mar 13, 2021

build failure attributed to #999

@Scottmitch
Copy link
Member Author

build failure attributed to #1192

Copy link
Contributor

@tkountis tkountis left a comment

Choose a reason for hiding this comment

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

Some suggestions then lgtm

Copy link
Contributor

@tkountis tkountis left a comment

Choose a reason for hiding this comment

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

🚀 🚀 Awesome work!

Motivation:
Executing multiple async operations in parallel and combining them in a
type safe way is a common use case, and referred to as zip [1]. We do
not support a zip operator which requires a careful sequence of
operators to replicate.

[1] http://reactivex.io/documentation/operators/zip.html

Modifications:
- Add Single.zipWith
- Add Single.zip overload for 3, 4, and varargs amount of Singles

Result:
Single.zip and Single.zipWith operators exist.
@Scottmitch Scottmitch merged commit 786eed8 into apple:main Mar 17, 2021
@Scottmitch Scottmitch deleted the single_zip branch March 17, 2021 20:11
bondolo pushed a commit to bondolo/servicetalk that referenced this pull request Mar 18, 2021
Motivation:
Executing multiple async operations in parallel and combining them in a
type safe way is a common use case, and referred to as zip [1]. We do
not support a zip operator which requires a careful sequence of
operators to replicate.

[1] http://reactivex.io/documentation/operators/zip.html

Modifications:
- Add Single.zipWith
- Add Single.zip overload for 3, 4, and varargs amount of Singles

Result:
Single.zip and Single.zipWith operators exist.
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.

3 participants