JBOSS EAP 6.4 - WebSocket Error
webmaster-3 Dec 23, 2016 3:54 AMHello,
I created a web application with websocket (EchoWebSocket).
in the file jboss-web.xml I enabled the websocket
<jboss-web>
<enable-websockets>true</enable-websockets>
</jboss-web>
and i configured the web connector to use the NIO2 protocol
<subsystem xmlns="urn:jboss:domain:web:2.2" default-virtual-server="default-host" native="false">
<connector name="http" protocol="org.apache.coyote.http11.Http11NioProtocol" scheme="http" socket-binding="http"/>
<virtual-server name="default-host" enable-welcome-root="true">
<alias name="localhost"/>
<alias name="example.com"/>
</virtual-server>
</subsystem>
if I use a JavaScript client application it works.
Instead if I use a C# client can it connects, but if I try to exchange messages I get the following exception
16:51:16,793 ERROR [org.apache.tomcat.websocket] (http-0.0.0.0:8080-118) JBWEB008809: No error handling configured for [com.wws.websocket.EchoWebSocket] and the following error occurred: java.nio.channels.ClosedChannelException
at org.apache.coyote.http11.InternalNioInputBuffer$1.completed(InternalNioInputBuffer.java:122) [jbossweb-7.5.19.Final-redhat-1.jar:7.5.19.Final-redhat-1]
at org.apache.coyote.http11.InternalNioInputBuffer$1.completed(InternalNioInputBuffer.java:117) [jbossweb-7.5.19.Final-redhat-1.jar:7.5.19.Final-redhat-1]
at org.apache.tomcat.util.net.NioChannel$1.completed(NioChannel.java:680) [jbossweb-7.5.19.Final-redhat-1.jar:7.5.19.Final-redhat-1]
at org.apache.tomcat.util.net.NioChannel$1.completed(NioChannel.java:676) [jbossweb-7.5.19.Final-redhat-1.jar:7.5.19.Final-redhat-1]
at sun.nio.ch.Invoker.invokeUnchecked(Invoker.java:126) [rt.jar:1.7.0_75]
at sun.nio.ch.Invoker$2.run(Invoker.java:218) [rt.jar:1.7.0_75]
at sun.nio.ch.AsynchronousChannelGroupImpl$1.run(AsynchronousChannelGroupImpl.java:112) [rt.jar:1.7.0_75]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_75]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_75]
at org.apache.tomcat.util.net.NioEndpoint$DefaultThreadFactory$1$1.run(NioEndpoint.java:1250) [jbossweb-7.5.19.Final-redhat-1.jar:7.5.19.Final-redhat-1]
at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
Why????
the same application works with Jboss EAP 7.0!!!
Thank you