重现问题的步骤:
1:在窗口环境中运行正常,EG:192.168.0.207:9091 / insert?id = 1 SUCCESS
2:打开DOS WINDOWS,在项目路径下:sbt-> dist生成目录
rserver /箱; rserver /配置; rserver / lib中; rserver /部署
3:将所有目录放在linux环境中
4:我写一个xshell(run.sh)来运行项目(它包含akka.kernel.Main类)
5:./ run.sh启动,控制台消息为
从Akka开始...
运行Akka 2.0.3
部署文件:/opt/playmini/deploy/cti-kernel-1.0.0.jar
========= start ==== record =============(见这里)
启动CtiKernel
播放服务器进程ID为8084
[info] play - 应用程序启动(Prod)
[info] play - 在/ 0上收听HTTP:0:0:0:0:0:0:0:9091
成功启动了Akka
对象RecordApp扩展了应用程序{
System.setProperty("http.port","9091")
System.setProperty("pidfile.path","/opt/pid")
val system = ActorSystem("RecordSystem")
val log = Logging.getLogger(RecordApp.system,this)
println("=========start====record=============")
def route = {
case GET(Path("/insert")) & QueryString(qs) => Action{ request =>
//val tenantId = QueryString(qs,"id").getOrElse(0)
println("context:" + request.contentType)
Ok("Pong1 @ %s\n".format(System.currentTimeMillis))
}
...
6:但是192.168.0.207:9091/insert?id=1 respose未找到操作对于请求'GET / insert?id = 1'
请告诉我原因