JobModule

When the application is launched, everything starts with JobModule. It configures the creation of Scheduler, which sends messages to SchedulerActor as given in the application.conf rate:

class JobModule extends AbstractModule with AkkaGuiceSupport {
def configure(): Unit = {
//configuring launch of price-fetching Actor
bindActor[SchedulerActor]("scheduler-actor")
bind(classOf[Scheduler]).asEagerSingleton()
}
}

To enable this module, inside application.conf, the following line is required:

play.modules.enabled += "modules.jobs.JobModule"
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset