Thursday 15 August 2013

scala - Call Method every x seconds -


I am using Scala and Play frameworks and I am trying to execute a method every 20 seconds.

The code I use is:

  val system = akka.actor.ActorSystem ("system") system.scheduler.schedule (0 seconds, 30 seconds (Worker ())  

It starts working, but after about 20 minutes this worker prevents the call from the law. What is the problem?


No comments:

Post a Comment