Hi Alexey,

Doug is currently working on a proposal for this for JDK9, perhaps
something for inspiration?
http://gee.cs.oswego.edu/dl/jsr166/dist/docs/java/util/concurrent/SubmissionPublisher.html

On Sun, Feb 8, 2015 at 5:54 PM, Alexey Romanchuk <[email protected]
> wrote:

> Hello again,
>
> My idea right now is to specify buffer size explicitly and return
> Future[Try[Unit]] that indicates result of enqueuing into buffered source.
> I am not sure that there is right way, but I need to connect some non
> stream based system with akka streams. Any thoughts?
>
> Unfortunately, I faced https://github.com/akka/akka/issues/16762 and
> right now it is impossible to provide high level API to custom sources
> instead of prebuilt ones.
>
> воскресенье, 25 января 2015 г., 20:09:07 UTC+6 пользователь √ написал:
>>
>> Hi Alexey,
>>
>> On Sat, Jan 24, 2015 at 11:20 AM, Alexey Romanchuk <[email protected]
>> > wrote:
>>
>>> Hey hakkers,
>>>
>>> I wonder why there is not such prebuilt Source that provides API to
>>> externally emit message by simple method call. I am talking about something
>>> like this:
>>>
>>> //building and starting flow
>>> val flow = ???
>>> val source = ExternalSource[String]
>>> source.via(flow).to(BlackholeSink).run
>>>
>>> //using source
>>> source.emit("")
>>>
>>
>> What would happen if it can't?
>>
>>
>>> source.complete()
>>> source.error(new Exception)
>>>
>>> It can be implemented manually using actor, buffer inside it and
>>> exposing some object that internally sends message to this actor. I think
>>> this source can be very useful in case of integration with external API.
>>>
>>
>> I agree, I think something like this could be quite useful, the "problem"
>> is getting the API right.
>>
>>
>>>
>>> Thanks
>>>
>>> p.s. Sure, we can not directly use ExternalSource to emit objects, but
>>> should use some object created during flow materialization, like PropSource
>>> does.
>>>
>>> --
>>> >>>>>>>>>> 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 http://groups.google.com/group/akka-user.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> --
>> Cheers,
>> √
>>
>  --
> >>>>>>>>>> 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 http://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Cheers,
√

-- 
>>>>>>>>>>      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 http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to