"invalid format version" p.nettyException with reproduction 2.2.1
My routes file looks like
GET / controllers.Application.index()
POST /get_token controllers.Application.getToken()
GET for '/' works fine. However, the POST for '/ get_token' fails with the following error message.
[error] p.nettyException - Exception caught in Netty
java.lang.IllegalArgumentException: invalid version format: =Dᅥメ$_!HBユHᅢW(+/゙ᅩᅩ
at org.jboss.netty.handler.codec.http.HttpVersion.<init>(HttpVersion.java:102) ~[netty.jar:na]
at org.jboss.netty.handler.codec.http.HttpVersion.valueOf(HttpVersion.java:62) ~[netty.jar:na]
at org.jboss.netty.handler.codec.http.HttpRequestDecoder.createMessage(HttpRequestDecoder.java:75) ~[netty.jar:na]
at org.jboss.netty.handler.codec.http.HttpMessageDecoder.decode(HttpMessageDecoder.java:189) ~[netty.jar:na]
at org.jboss.netty.handler.codec.http.HttpMessageDecoder.decode(HttpMessageDecoder.java:101) ~[netty.jar:na]
at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:500) ~[netty.jar:na]
I am using play-2.2.1.
I am relatively newbie. Can anyone help me?
Thanks in advance!
+3
source to share
1 answer
Are you connecting via https? If so, you may not have a certificate installed.
The simplest solution would be to connect via http instead of https. If you really want https, you can create a self-signed certificate:
keytool -genkey -alias MyKey -keyalg RSA -keysize 2048 -keystore keystore.jks
play -Dhttps.port=9443 -Dhttps.keyStore=keystore.jks -Dhttps.keyStorePassword=password run
+1
source to share