scala - Spray Routing template not working -
i try run spray template @ https://github.com/spray/spray-template.
i error @ step 5 (start application)
[error] [04/26/2015 12:49:18.613] [on-spray-can-akka.actor.default-dispatcher-4] [akka://on-spray-can/user/io-http/listener-0] 762 akka.actor.actorinitializationexception: exception during creation @ akka.actor.actorinitializationexception$.apply(actor.scala:164) @ akka.actor.actorcell.create(actorcell.scala:596) @ akka.actor.actorcell.invokeall$1(actorcell.scala:456) @ akka.actor.actorcell.systeminvoke(actorcell.scala:478) @ akka.dispatch.mailbox.processallsystemmessages(mailbox.scala:279) @ akka.dispatch.mailbox.run(mailbox.scala:220) @ akka.dispatch.mailbox.exec(mailbox.scala:231) @ scala.concurrent.forkjoin.forkjointask.doexec(forkjointask.java:260) @ scala.concurrent.forkjoin.forkjoinpool$workqueue.runtask(forkjoinpool.java:1339) @ scala.concurrent.forkjoin.forkjoinpool.runworker(forkjoinpool.java:1979) @ scala.concurrent.forkjoin.forkjoinworkerthread.run(forkjoinworkerthread.java:107) caused by: java.lang.arrayindexoutofboundsexception: 762 @ spray.can.parsing.httpheaderparser.insert(httpheaderparser.scala:231) @ spray.can.parsing.httpheaderparser$.insertingoodorder$1(httpheaderparser.scala:422) @ spray.can.parsing.httpheaderparser$.apply(httpheaderparser.scala:429) @ spray.can.parsing.httprequestpartparser$.$lessinit$greater$default$3(httprequestpartparser.scala:28) @ spray.can.server.requestparsing$.apply(requestparsing.scala:36) @ spray.can.server.httpserverconnection$.pipelinestage(httpserverconnection.scala:217) @ spray.can.server.httplistener.<init>(httplistener.scala:36) @ spray.can.httpmanager.newhttplistener(httpmanager.scala:84) @ spray.can.httpmanager$$anonfun$receive$1$$anonfun$applyorelse$1.apply(httpmanager.scala:76) @ spray.can.httpmanager$$anonfun$receive$1$$anonfun$applyorelse$1.apply(httpmanager.scala:76) @ akka.actor.typedcreatorfunctionconsumer.produce(props.scala:343) @ akka.actor.props.newactor(props.scala:252) @ akka.actor.actorcell.newactor(actorcell.scala:552) @ akka.actor.actorcell.create(actorcell.scala:578) ... 9 more
java version
java version "1.7.0_80" java(tm) se runtime environment (build 1.7.0_80-b15) java hotspot(tm) 64-bit server vm (build 24.80-b11, mixed mode)
the problem faced caused of operation system's language.
you should add these 2 lines build.sbt
fork in run := true javaoptions in run ++= seq("-duser.language=en", "-duser.country=us", "-dfile.encoding=utf-8")
after adding them, problem solved.
Comments
Post a Comment