twi*_*imo 4 playframework playframework-2.0
我知道我可以通过使用-Dconfig.file标志使Play服务器使用其他application.conf文件。
有没有办法指定服务器使用其他路由文件?
您可以在application.conf中设置它或使用JVM标志
-Dapplication.router=my.application.Routes
# Router
# ~~~~~
# Define the Router object to use for this application.
# This router will be looked up first when the application is starting up,
# so make sure this is the entry point.
# Furthermore, it's assumed your route file is named properly.
# So for an application router like `conf/my.application.Router`,
# you may need to define a router file `my.application.routes`.
# Default to Routes in the root package (and `conf/routes`)
# application.router=my.application.Routes
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2585 次 |
| 最近记录: |