Open rkuhn opened 8 years ago
Originally I emit not Confirmation
, but Future[Confirmation]
. This allows client to keep order of messages and perform some actions in parallel and then join confirmed record with some other job.
Emitting just Confirmation
shuffles original order.
Also Future[Confirmation]
can be easily turned into Confirmation
and allows client to control how many confirmation may be in progress.
Ah, my assumption was that the .mapAsync()
is already included in the KafkaSink and that the confirmations are emitted in the right order.
I wanted to provide as minimal abstraction as possible. Then client will decide do he cares about order (and use mapAsync) or dont (and use mapAsyncUnordered)
Same for #13
Yes, this is a good point. This case is rather easy, the Source case is vastly different due to needing three ports.
I agree with https://github.com/akka/akka-meta/issues/14#issuecomment-195453520 in that we'll want to expose Future[Confirmation]
, from which can go to Confirmation with or without order :+1:
This is the much simpler cousin of #13. The primary proposal is to model this as a Flow:
This is fundamentally what happens: messages are sent to Kafka, to be turned into confirmations.