在play/scala
中启动IntelliJ
应用程序时,出现以下错误Uncaught error from thread [play-dev-mode-akka.actor.default-dispatcher-2]: null, shutting down JVM since 'akka.jvm-exit-on-fatal-error' is enabled for ActorSystem[play-dev-mode]
java.lang.StackOverflowError
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
该错误发生在代码lazy val httpRequestHandler: HttpRequestHandler = new DefaultHttpRequestHandler(router, httpErrorHandler, httpConfiguration, httpFilters: _*)
的下一行。这不是我的代码。我可以在堆栈跟踪(apploader.scala)中看到的代码的第一项是
lazy val userController = new UserController(credentialsProvider,application.configuration, utilities,userRepository, userTokenRepository,mailerService,controllerComponents, silhouetteJWTProvider,messagesApi,langs)
UserController
的定义如下:
class UserController (credentialsProvider:CredentialsProvider,config:Configuration, utilities:HelperMethods, userRepo: UsersRepository,userTokenRepo:UserTokenRepository, mailerService:MailerService, cc: ControllerComponents, silhouette: Silhouette[JWTEnv],messagesApi: MessagesApi,langs:Langs)(implicit exec: ExecutionContext) extends AbstractController(cc){
我看到了SO上的解决方案,其中显示了如何禁用功能(disable akka.jvm-exit-on-fatal-error for actorsystem in java),但是我认为允许jvm
运行StackOverflowError
并不是一个好主意。我不知道是什么原因引起的。
为什么会出现错误?在我看来,由于堆栈跟踪是重复的,因此代码似乎在某种程度上循环运行。
Server started, use Alt+D to stop
practice question Javascript repo is practice_questions_javascript_tag
practice question html repo is practice_questions_html_tag
[warn] c.d.d.c.Cluster - You listed localhost/0:0:0:0:0:0:0:1:9042 in your contact points, but it wasn't found in the control host's system.peers at startup
database will connect with keyspace Some(codingjedi)
(keyspace is ,codingjedi)
user repo is users
app loader: csrf values: csrfToken, Some(CJCsrfCookie), CJCsrfHeader
Uncaught error from thread [play-dev-mode-akka.actor.default-dispatcher-2]: null, shutting down JVM since 'akka.jvm-exit-on-fatal-error' is enabled for ActorSystem[play-dev-mode]
java.lang.StackOverflowError
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at play.api.BuiltInComponents.httpRequestHandler$(Application.scala:321)
at play.api.BuiltInComponentsFromContext.httpRequestHandler$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.httpRequestHandler(ApplicationLoader.scala:122)
at play.api.BuiltInComponents.application(Application.scala:324)
at play.api.BuiltInComponents.application$(Application.scala:323)
at play.api.BuiltInComponentsFromContext.application$lzycompute(ApplicationLoader.scala:122)
at play.api.BuiltInComponentsFromContext.application(ApplicationLoader.scala:122)
at app.AppComponents.userController$lzycompute(AppLoader.scala:357)
at app.AppComponents.userController(AppLoader.scala:357)
at app.AppComponents.userWSRoutes$lzycompute(AppLoader.scala:377)
at app.AppComponents.userWSRoutes(AppLoader.scala:377)
at app.AppComponents.router$lzycompute(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:379)
at app.AppComponents.router(AppLoader.scala:128)
at play.api.BuiltInComponents.httpRequestHandler(Application.scala:321)
at ...
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256M; support was removed in 8.0
答案 0 :(得分:0)
我还没有完全调试问题,但是看来我应该使用configuration
提供的BuiltInComponentsFromContext
对象,而不是application.configuration
。我将userRepository
的定义更改为以下内容,并且代码起作用了。
lazy val userController = new UserController(credentialsProvider,configuration, utilities,userRepository, userTokenRepository,mailerService,controllerComponents, silhouetteJWTProvider,messagesApi,langs)