Hello Prakhyat, have you seen this article <http://techblog.net-a-porter.com/2013/12/ask-tell-and-per-request-actors/> which discusses ask vs tell patterns?
I assume from the other thread, that you are using Java. To sum up the mentioned article, if you use Play framework for handling REST calls, you could return a Future from the controller. That future would be fulfilled by the promise in the per-request actor. On Thu, Oct 9, 2014 at 9:57 AM, Prakhyat Mallikarjun <[email protected]> wrote: > Team, > > We are working on a simple POC. The POC is developed on the approach event > sourcing/DDD/CQRS. > > The PersistentActors are shaded. PersistentViews are created to push > events from write side towards query side. > > The business logic resides in PersistentActors. The rest API's are > written to invoke PersistentActors. The rest layer invokes PersistentActor > and waits for response. This looks like synchronous, we are using Ask > pattern. The rest layer has to wait till the PersistentActor is done with > business logic and returns. > > The ask pattern comes with a cost i.e. to specify timeout while making a > call to other actor. If the response is not received within timeout > specified, exception will be raised. > > Tell in other perspective is asynchronous. The actor making a "tell" call > need not wait for response. > > What are your recommendations/insights on using tell vs ask? > > -Prakhyat M M > > > > -- > >>>>>>>>>> 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. > -- Martynas Mickevičius Typesafe <http://typesafe.com/> – Reactive <http://www.reactivemanifesto.org/> Apps on the JVM -- >>>>>>>>>> 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.
