Hmm, Ok. As for backpressure, with these there should be none because only the latest values emitted by the listener are useful. So I guess I would set them to have a buffer of size 1 and to drop the oldest elements in the buffer for that effect right?
On Monday, August 29, 2016 at 8:33:31 AM UTC+2, Tal Pressman wrote: > > Hi, > > You could use an ActorPublisher (Source.actorPublisher) and send it > messages from the listener. Just remember to handle backpressure - what do > you do if the listener is called but the stream isn't ready to accept > messages yet? > > Tal > > On Monday, August 29, 2016 at 12:26:34 AM UTC+3, Mark Hammons wrote: >> >> I am writing a scheduler for mesos, and I'd like to construct it >> completely from streams instead of the listener functions it currently >> uses. How would I create a source and emit items when the listening hooks >> are called? >> >> >> >> Thanks >> -- >> >> Mark Hammons - +33 06 03 69 56 56 >> >> Research Engineer @ BioEmergences <http://bioemergences.iscpif.fr> >> >> Lab Phone: 01 69 82 34 19 >> > -- >>>>>>>>>> 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.
