On Tue, Dec 20, 2016 at 11:34 PM, Anil Gursel <[email protected]> wrote:
> I see that unzip does not pull the next element when fusing is on. I > understand that when fusing is on, a message goes through the entire stream > and then the next message goes through. > This is not true, messages are handled concurrently even in fused islands, it is just that they are not parallel. I.e. same thread, but event order is unspecified. In fact, fused islands are fair in that even in the case of long-running cycles other parts of the graph can still progress (which would not be true if what you said would be true) > However, is it still the case when `mapAsyncUnordered` is used? > mapAsync wait on asynchronous events, so that needs to wait until those are ready. In the meantime the rest of the graph can progress. > > Please see the two tests at https://gist.github.com/anilgursel/ > aa70497a9431fc8b498c599d9d469e2b. The two tests are identical except the > second one does an unzip then a zip. The first one succeeds and the second > one fails. The first one succeeding means that when `mapAsyncUnordered` is > used, it is not actually waiting for the previous message to go through the > entire stream. > Again, there is no "previous message go through the entire stream". That would lead to starving scenarios that you describe. What fusing changes is that it removes buffers and hence prefetches. Try out higher delays and see what happens. -Endre > > I will appreciate if you can shed some light on what's going on in this > samples. > > Thanks, > Anil > > -- > >>>>>>>>>> Read the docs: http://akka.io/docs/ > >>>>>>>>>> Check the FAQ: http://doc.akka.io/docs/akka/ > current/additional/faq.html > >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user > --- > You received this message because you are subscribed to the Google Groups > "Akka User List" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > Visit this group at https://groups.google.com/group/akka-user. > For more options, visit https://groups.google.com/d/optout. > -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
