哎呀.conf/routes或conf/application.conf缺失.?

new*_*bie 1 java playframework

我在官方网站上关注了" 学习 ".我正在使用Windows 7 + Chrome.

  D:\tester\play>dir
 Volume in drive D is APPLIS
 Volume Serial Number is 9037-F7BD

 Directory of D:\tester\play

07/15/2011  10:38 PM    <DIR>          .
07/15/2011  10:38 PM    <DIR>          ..
06/15/2011  11:00 AM             1,810 COPYING
07/15/2011  10:33 PM    <DIR>          documentation
07/15/2011  10:34 PM    <DIR>          framework
07/15/2011  10:35 PM    <DIR>          modules
06/06/2011  08:10 PM             5,858 play
06/06/2011  08:10 PM                50 play.bat
07/15/2011  10:35 PM    <DIR>          python
06/06/2011  08:10 PM             1,834 README.textile
07/15/2011  10:35 PM    <DIR>          resources
07/15/2011  10:33 PM    <DIR>          samples-and-tests
07/15/2011  10:35 PM    <DIR>          support
07/15/2011  10:53 PM    <DIR>          yabe
               4 File(s)          9,552 bytes
              10 Dir(s)  100,984,504,320 bytes free

D:\tester\play>play run
~        _            _
~  _ __ | | __ _ _  _| |
~ | '_ \| |/ _' | || |_|
~ |  __/|_|\____|\__ (_)
~ |_|            |__/
~
~ play! 1.2.2, http://www.playframework.org
~
~ Oops. conf/routes or conf/application.conf missing.
~ D:\tester\play does not seem to host a valid application.
~


D:\tester\play>play run yabe
~        _            _
~  _ __ | | __ _ _  _| |
~ | '_ \| |/ _' | || |_|
~ |  __/|_|\____|\__ (_)
~ |_|            |__/
~
~ play! 1.2.2, http://www.playframework.org
~
~ Ctrl+C to stop
~
Listening for transport dt_socket at address: 8000
23:09:24,780 INFO  ~ Starting D:\tester\play\yabe
23:09:31,483 WARN  ~ You're running Play! in DEV mode
23:09:32,615 ERROR ~ Could not bind on port 9000
Run Code Online (Sandbox Code Playgroud)

现在我正在等待解决这个问题所以我可以继续学习播放下一步.

我尝试谷歌但是我没有得到我的理由的好答案.

有人可以帮帮我吗?

Cod*_*nci 5

Oops. conf/routes or conf/application.conf missing是误导你,这只是因为你试图启动Play应用程序而没有指定要运行的应用程序.只是键入play run会导致错误,因为没有应用程序在当前目录中运行.相反,你只需要输入play run yabe.

您的第二个错误,Unable to bind to port 9000通常意味着该端口上已经存在某些内容.

最简单的方法是更改​​运行Play的端口并重新启动服务器.

为此,只需打开yabe/app/conf/application.conf文件,然后更改此行

# http.port=9000
Run Code Online (Sandbox Code Playgroud)

http.port=9001
Run Code Online (Sandbox Code Playgroud)

并继续增加数字,直到找到一个自由端口.如果你超过9005,你可能会更好地进行端口扫描,看看哪些端口正在使用,而不是永远持续下去!