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
Stream.mergeAll blocks until first element appeared in each stream #135
Comments
Hmm... This does look like a potential bug. Perhaps in |
@polytypic, I almost fixed the issue but I had a question during the writing tests. I have infinite streams in my case so I've never asked myself about it. What is the expected result from the merge of |
So |
It seems there is bug in
Stream.mergeAll
method. In this example I create 5 channels with 3 jobs whose push work items to first 3 channels. Then I define indefiniteStream
for each channel and merge them withStream.mergeAll
combinator.In the result, I have only 3 first items taken from Stream and then the application is blocked. There are two commented lines, and uncommenting any of these lines (with commenting line below) fixes the problem. In the first comment I send the single message to each "idle" channel, in the second comment I use
Seq.fold
over the sequence of streams instead of usingofSeq
andmergeAll
combinators.The text was updated successfully, but these errors were encountered: