Closed He-Pin closed 3 months ago
BTW, I have a question:
if a server provide a java-client using java completeFuture and a mono/flux client. Which should I use in pekko-streams api?
use completeFuture client, I can writer code Source.future(completeFuture.asScala)
, or use the other like this PR
@laglangyue You can convert a Publisher to Pekko's Source, and a Pekko's Sink as a Publisher too, I mostly using CompletableFuture at $Work, but will use Pekko Stream when it fit best.
Generally looks ok but I'd prefer not to merge this till we split off a 1.0.x branch.
LGTM
Thanks.
Motivation:
toFuture.asScala
seems quite boring, we can convert it to Scala Future directly.Result: Less allocation/conversion