Play Scala and thread safety
问题 The project is written using Play framework and Scala language. I have implemented compile time dependency . I have followed this example from Play: https://github.com/playframework/play-scala-compile-di-example Looking at the MyApplicationLoader.scala : import play.api._ import play.api.routing.Router class MyApplicationLoader extends ApplicationLoader { private var components: MyComponents = _ def load(context: ApplicationLoader.Context): Application = { components = new MyComponents