Hi, Don't worry about it, we all make mistakes.
On Fri, Jul 11, 2014 at 9:29 AM, Matija Novak <[email protected]> wrote: > Hi, > > thank you. I took another try with this. It turned out that my unit test > failed due to a tiny mistake in code. I feel stupid about this now... > > Regards, Matija > > > On Thursday, July 10, 2014 4:44:40 PM UTC+2, √ wrote: > >> akka.patterns.Patterns.after: >> >> static<T> scala.concurrent.Future<T> *after >> <http://doc.akka.io/japi/akka/2.3.4/akka/pattern/Patterns.html#after(scala.concurrent.duration.FiniteDuration,+akka.actor.Scheduler,+scala.concurrent.ExecutionContext,+java.util.concurrent.Callable)>* >> (scala.concurrent.duration.FiniteDuration duration,Scheduler >> <http://doc.akka.io/japi/akka/2.3.4/akka/actor/Scheduler.html> scheduler, >> scala.concurrent.ExecutionContext context, java.util.concurrent.Callable< >> scala.concurrent.Future<T>> value) >> Returns a Future that will be completed with the success or >> failure of the provided Callable after the specified duration. >> >> >> >> On Thu, Jul 10, 2014 at 4:40 PM, Matija Novak <[email protected]> >> wrote: >> >>> Hi, >>> >>> I am trying to delay task execution, but failed to do so without >>> blocking the execution context. Akka scheduler is no good for me, since I >>> need to have access to the result of the task at some point. Implementing >>> delay in task execution (sleeping) causes blocking, which is also >>> unacceptable. >>> >>> I have also tried Patterns.after pattern, but this only delays >>> completion of the Future, not the execution of given task itself. >>> >>> I ended up with blocking solution though: >>> >>> future(new Callable<TaskResult>() { >>> public TaskResult call() throws Exception { >>> sleep(delay); >>> TaskResult rslt = exec(); >>> return rslt; >>> } >>> }, CTX); >>> >>> but am very unhappy with it... >>> >>> I am struggling with this issue for couple of hours now, hope someone >>> can give me a hint or two. >>> >>> >>> -- >>> >>>>>>>>>> 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.
