-
Notifications
You must be signed in to change notification settings - Fork 128
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
ConcatMap operator without prefetch #997
Conversation
Codecov Report
@@ Coverage Diff @@
## main #997 +/- ##
============================================
+ Coverage 89.10% 89.26% +0.15%
- Complexity 3137 3150 +13
============================================
Files 412 413 +1
Lines 12566 12697 +131
Branches 1586 1617 +31
============================================
+ Hits 11197 11334 +137
+ Misses 717 708 -9
- Partials 652 655 +3
|
@ozangunalp and I discussed this yesterday. My proposal is the following:
|
@jponge how do you want to proceed for the target branch? main and backport to 1.x, or 2 PRs? Note the discussion above that it may not be "just a backport", but a change of the default behavior. |
Ok, let me add a couple more test cases. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The operator looks good.
implementation/src/main/java/io/smallrye/mutiny/operators/multi/MultiConcatMapOp.java
Outdated
Show resolved
Hide resolved
...rc/test/java/io/smallrye/mutiny/tcktests/MultiConcatMapNoPrefetchCompletionStageTckTest.java
Outdated
Show resolved
Hide resolved
implementation/src/main/java/io/smallrye/mutiny/operators/multi/MultiConcatMapOp.java
Show resolved
Hide resolved
This PR is a feature / enhancement, so the target is 2.0. If you want this in 1.x then yes you'll need a separate PR for the |
If there's a "backport" the target for it will be 1.7.0. |
9fb9137
to
1de6276
Compare
To recap this PR targets the main branch (2.0) with |
Thanks Ozan, I’ll get back to this next Monday.
…On Fri, Jul 22, 2022, at 18:53, Ozan Gunalp wrote:
To recap this PR targets the main branch (2.0) with `concatenate` methods defaulting to no prefetch.
Another PR will target 1.x branch for 1.7, keeping the default behaviour of prefetching on `concatenate` methods.
—
Reply to this email directly, view it on GitHub <#997 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AAAGK2I3YPT5SKZF5Y66VUTVVLG2NANCNFSM54HIDC6Q>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
…entation. * Default for onItem().transformToUni/Multi().concatenate * Added entrypoint MultiFlatten.concatanate(prefetch)
1de6276
to
90a50f7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @ozangunalp
Any further change or are we ready to merge? |
Thanks @jponge. It is ready to merge. |
Requests are forwarded lazily to the upstream when:
Added entrypoints
Multi.concatMap(mapper, prefetch)
andMultiFlatten.concatanate(prefetch)
.Existing
transformTo[Uni|Multi]AndConcatanate
methods default toprefetch=true
for backwards compatible behavior.Typically this operator allows applying async transformation on each item of a Multi, without prefetching an additional item from the upstream.