scaldi

why cant I bind to single actor instance (akka router) with scaldi?

ぃ、小莉子 提交于 2019-12-25 11:27:11
问题 I´m currently struggeling with implementing my Akka router logic using scaldi for dependency injection. Why cant I bind to a single actor instance with scaldi, since my actor is a router and I only want to have one single instance of it? The way I came to ask this question was another stackoverflow entry. My scaldi Module: class DAOModule extends Module { bind toProvider new UserDaoWorker binding to new UserDaoRouter } This way only one instance is created and as soon as I inject my router

why cant I bind to single actor instance (akka router) with scaldi?

橙三吉。 提交于 2019-12-25 11:27:10
问题 I´m currently struggeling with implementing my Akka router logic using scaldi for dependency injection. Why cant I bind to a single actor instance with scaldi, since my actor is a router and I only want to have one single instance of it? The way I came to ask this question was another stackoverflow entry. My scaldi Module: class DAOModule extends Module { bind toProvider new UserDaoWorker binding to new UserDaoRouter } This way only one instance is created and as soon as I inject my router

ReactiveMongo ConnectionNotInitialized In Test After Migrating to Play 2.5

倖福魔咒の 提交于 2019-12-24 05:44:23
问题 After migrating my Play (Scala) app to 2.5.3, some tests of my code using ReactiveMongo that once passed now fail in the setup. Here is my code using ScalaTest: def fixture(testMethod: (...) => Any) { implicit val injector = new ScaldiApplicationBuilder() .prependModule(new ReactiveMongoModule) .prependModule(new TestModule) .buildInj() def reactiveMongoApi = inject[ReactiveMongoApi] def collection: BSONCollection = reactiveMongoApi.db.collection[BSONCollection](testCollection) lazy val id =