onError got involved for component [events] with session id [0]
java.lang.NullPointerException
at org.lucee.extension.websocket.WebSocketEndpointFactory.register(WebSocketEndpointFactory.java:96)
at org.lucee.extension.websocket.WebSocketEndpointFactory.setSessions(WebSocketEndpointFactory.java:292)
at org.lucee.extension.websocket.BaseWebSocketEndpoint.onOpen(BaseWebSocketEndpoint.java:103)
at org.lucee.extension.websocket.JavaxWebSocketEndpoint.onOpen(JavaxWebSocketEndpoint.java:32)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.apache.tomcat.websocket.pojo.PojoEndpointBase.doOnOpen(PojoEndpointBase.java:67)
at org.apache.tomcat.websocket.pojo.PojoEndpointServer.onOpen(PojoEndpointServer.java:46)
at org.apache.tomcat.websocket.server.WsHttpUpgradeHandler.init(WsHttpUpgradeHandler.java:131)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:978)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1791)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:52)
at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1190)
at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:63)
at java.base/java.lang.Thread.run(Thread.java:829)
I'm using websocket 1.0.0.11-RC (I've also tried 1.0.0.4-BETA) and lucee docker, I've tried multiple versions: 6.0.3.1, 6.1.0.235-RC and 6.2.0.1-SNAPSHOT. Lucee is running in single mode on Tomcat.
I'm sure I'm doing something wrong because the only way to make it work is by replacing line 100 in source/java/src/org/lucee/extension/websocket/util/WSUtil.java with return cw;.
I've been trying to use websocket extension by following https://github.com/lucee/lucee-docs/blob/master/docs/recipes/websocket-extension.md but always get
NullPointerException
when client connects to websocket:I'm using websocket 1.0.0.11-RC (I've also tried 1.0.0.4-BETA) and lucee docker, I've tried multiple versions: 6.0.3.1, 6.1.0.235-RC and 6.2.0.1-SNAPSHOT. Lucee is running in single mode on Tomcat. I'm sure I'm doing something wrong because the only way to make it work is by replacing line 100 in source/java/src/org/lucee/extension/websocket/util/WSUtil.java with
return cw;
.