java在playframework项目上配置死锁
您好,我在playframework项目中配置死锁模块时遇到了一个小问题。我使用的是PlayFramework2.2.1版本,我一步一步地做,就像他们在deadbolt文档页面上显示的那样 http://deadbolt.ws/#/java-docs
我遇到的第一个问题是申请。因为我在这里看到的是这样的:
# This is the main configuration file for the application.
# ~~~~~
# Secret key
# ~~~~~
# The secret key is used to secure cryptographics functions.
# If you deploy your application to several instances be sure to use the same key!
application.secret="0ki/vB`gn_SY]NWR;8I0OM1^/<>3AF;dMG^VFc8JQ5sGJ9eL4:/7Hpc2/y>Ug;bu"
# The application languages
# ~~~~~
application.langs="en,de"
parsers.text.maxLength=10000000K
deadbolt.java.handler
deadbolt {
before-auth-check-timeout=4000,
java {
cache-user=true,
handlers {
defaultHandler=com.example.security.MyDeadboltHandler,
be.objectify.deadbolt.java.DeadboltHandler,
be.objectify.deadbolt.core.models.Subject,
foo=com.example.security.FooDeadboltHandler,
be.objectify.deadbolt.java.DynamicResourceHandler,
bar=com.example.security.BarDeadboltHandler
}
}
}
# Global object class
# ~~~~~
# Define the Global object class for this application.
# Default to Global in the root package.
# application.global=Global
我不知道,我添加了良好的门闩配置,因为它看起来有点不同于其他应用。形态
启动“播放应用程序”“播放调试”~运行时
有东西正在更新和安装,然后我得到了错误
[info] Done updating.
java.lang.NoSuchMethodException:
play.core.server.NettyServer.mainDevHttpMode(play.core.SBTLink,
play.core.SBTDocHandler, int)
at java.lang.Class.getMethod(Class.java:1665)
at play.PlayRun$$anonfun$playRunTask$1$$anonfun$apply$1.apply(PlayRun.scala:232)
at play.PlayRun$$anonfun$playRunTask$1$$anonfun$apply$1.apply(PlayRun.scala:91)
at scala.Function7$$anonfun$tupled$1.apply(Function7.scala:35)
at scala.Function7$$anonfun$tupled$1.apply(Function7.scala:34)
at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47)
[trace] Stack trace suppressed: run last compile:run for the full output.
[error] (compile:run) java.lang.NoSuchMethodException:
play.core.server.NettyServer.mainDevHttpMode(play.core.SBTLink,
play.core.SBTDocHandler, int)
[error] Total time: 6 s, completed 2014-09-17 13:00:41
1. Waiting for source changes... (press enter to interrupt)
也许有人有这个问题,或者知道我做错了什么,我会非常感谢你的帮助
# 1 楼答案
看起来你的处理器块也错了。它应该是键/值对,但其中只有一对。它应该看起来更像