Have you seen Source.queue? Does that not get you what you are describing?

Brian Maso

On Thu, Nov 7, 2019 at 1:55 AM Bishnu Shankar Pandey <
bishnu.pan...@flutura.com> wrote:

> I saw the Example. I tried implementing it with queue but the issue that I
> am facing is that if the queue becomes empty fr some time the stream is
> getting completed. Is there any way to create a continuous stream source
> and if there if the queue is empty wait till it got any element and then
> send it to the actor.
>
> On Thursday, November 7, 2019 at 3:14:22 PM UTC+5:30, Felix Nensa wrote:
>>
>> Well, a GraphStage has a shape which you can define. If you define your
>> GraphStage to have an Outlet but no Inlet then it obviously becomes a
>> Source, right?
>> By Source.fromGraph(..your GraphStage ..) you can convert it into a
>> Source.
>> Or just look at the „NumbersSource“ example in
>> https://doc.akka.io/docs/akka/current/stream/stream-customize.html#custom-processing-with-graphstage
>> The name „NumbersSource“ even tells you that this GraphStage is a Source.
>
> --
>
> *****************************************************************************************************
> ** New discussion forum: https://discuss.akka.io/ replacing akka-user
> google-group soon.
> ** This group will soon be put into read-only mode, and replaced by
> discuss.akka.io
> ** More details:
> https://akka.io/blog/news/2018/03/13/discuss.akka.io-announced
>
> *****************************************************************************************************
> >>>>>>>>>>
> >>>>>>>>>> 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 akka-user+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/akka-user/544b3e8e-2de7-4f1d-a1e9-4575926d2b03%40googlegroups.com
> <https://groups.google.com/d/msgid/akka-user/544b3e8e-2de7-4f1d-a1e9-4575926d2b03%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
*****************************************************************************************************
** New discussion forum: https://discuss.akka.io/ replacing akka-user 
google-group soon.
** This group will soon be put into read-only mode, and replaced by 
discuss.akka.io
** More details: https://akka.io/blog/news/2018/03/13/discuss.akka.io-announced
*****************************************************************************************************
>>>>>>>>>> 
>>>>>>>>>>      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 akka-user+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/akka-user/CAPMeo2-G2W9RwkaMPfVi3PQFyEZf-52v3uOxnXDctBETvGxWkw%40mail.gmail.com.

Reply via email to