Websocket Getting Started and Lucee Docker

Hi. I am trying to get the WebSockets extension working with Lucee in Docker. I have watched the videos.

I am following the Getting Started page from here:

and am confused by this requirement:
Save the jar file servlet-filter-utils-1.1.1.jar to the classpath

Where do I get that jar from? I am new to Lucee so I might be missing the obvious. On the other hand, the instructions are 5 years old so things might have changed.

Thanks,
Murray

Hmmm… I just found this: https://lucee.daemonite.io/t/troubleshooting-lucee-websockets-with-iis-and-arr/2687/12

which suggests WebSockets on Lucee is broken.

Is that the case?

Thanks,
Murray

Have you seen this example?

https://lucee.daemonite.io/t/port-8888-not-working-websockets/6551/15?u=andreas

I’ve never used Websockets extensively, just some tests, so others will probably have more experience to tell you.

Also: IIS won’t work with boncode to connect to websocket. See BonCode Apache Tomcat AJP 1.3 Connector

Hope this helps a little.

Thanks @andreas. No, I missed that one. I will have a look.
Cheers,
Murray

Also check out this pull request with improved documentation:

https://github.com/isapir/lucee-websocket/pull/28

1 Like

Thanks @psarin.

So, here is a repo with some working code based on the Chat example and the various updates over the years.

https://github.com/flowt-au/Lucee-websocket-chat

Thanks to @andreas and @psarin. :slight_smile:

I hope that helps others.
Murray

Thank you @flowt-au for the great write up. Going to try it out as soon as I can.

Has anyone been able to get websockets working with commandbox? Keep getting a HTTPSessionFilter not initialized error, even though have the jar file and config in web.xml per instructions

1 Like

Websockets do not work with the latest version of Lucee. They stopped working when Lucee starting shipping with Tomcat 9 (not sure which version). Igal has basically told me he is not interested in doing any work on his extension to make them work. I’ve heard chatter that websockets will be supported in Lucee 6, but I haven’t had any luck getting more information about when/if that is the case, and if it is, whether it would be offered as a Lucee 5 extension.

Might want to follow this websocket issue I created: [LDEV-3815] - Lucee

I am running websockets successfully on Windows using Tomcat 9.0.46 and Lucee 5.3.9.160.

@Redtopia - check out the following where I try to detail my use of a proxy from the websocket listener. It has been working very well for me and may solve some of you issues: Multiple Endpoints may not be deployed to the same path · Issue #9 · isapir/lucee-websocket · GitHub

@psarin - I have not tried Commandbox however…

1 Like

To echo @martin , we have been able to use Websockets with Lucee on Apache Tomcat/9.0.56. On this setup, it’s been working pretty well and has been stable since using @martin 's code for the multiple endpoints may not be deployed issue.

With regards to Websockets on Commandbox/Lucee, still not able to get it working. Seems to be stuck on trying to upgrade the connection.

2 Likes