Hello,
If you do the following:
future1 map { r => agent.send(1) }
future2 map { r => agent.send(2) }
The order of the sends will be determined by the length of future1 and
future2.
I would expect something like
agent.sendOff(future1 map { r => 1 })
agent.sendOff(future2 map { r => 2 })
In a way the sends are applied in order.
Regards,
partycoder
On Thursday, February 13, 2014 3:43:14 AM UTC-8, rkuhn wrote:
>
> Hi partycoder,
>
> in which way does your code cause an ordering problem? What do you observe
> and why is that not as it should be?
>
> Regards,
>
> Roland
>
> 12 feb 2014 kl. 06:36 skrev [email protected] <javascript:>:
>
> Hello,
>
> I have a question.
>
> val f = some future
> val a = Agent(some type)
>
> // This may cause an ordering problem
> f map { result => a.send(result) }
>
> How do I use agent.send/sendOff using futures?
>
> Regards
>
> --
> >>>>>>>>>> Read the docs: http://akka.io/docs/
> >>>>>>>>>> Check the FAQ: http://akka.io/faq/
> >>>>>>>>>> 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] <javascript:>.
> To post to this group, send email to [email protected]<javascript:>
> .
> Visit this group at http://groups.google.com/group/akka-user.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
>
> *Dr. Roland Kuhn*
> *Akka Tech Lead*
> Typesafe <http://typesafe.com/> – Reactive apps on the JVM.
> twitter: @rolandkuhn
> <http://twitter.com/#!/rolandkuhn>
>
>
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ: http://akka.io/faq/
>>>>>>>>>> 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/groups/opt_out.