Closed redtopia closed 7 years ago
The connector is an intermediary between iis and tomcat, it does not directly talk to clients. Thus, iis will need to enable the sockets. IIS does support websockets but only iis 8 and later. https://www.iis.net/learn/get-started/whats-new-in-iis-8/iis-80-websocket-protocol-support
You will have to register the handler for the socketendpoint you wish to use. However, I have not tried this myself.
Alternately you can connect to tomcat directly as you stated.
Yes, I understand that the Boncode Connector is not a web server and would not "handle" the websocket connection itself. Apps that use the Boncode Connector to connect IIS with Tomcat need a way for websocket requests to be passed to Tomcat.
Currently, Lucee's support for websockets is done using a new Lucee extension, which uses the Tomcat websocket library. I am thinking that the Boncode Connector would be able to take websocket requests that are received in IIS and pass them to Tomcat to be handled. Am I wrong about that?
You are correct. I summarized my understanding.
Currently the connector is not web-socket aware. I do think this would need to change and it would need to be made websockets aware for it to handle long running connections. We would also need to standardize how each message from the client should be passed to a given endpoint.
You can try to enable as is. Afaik you need to set the handler registration in IIS to support websocket, you can do this for one file:
var host = "ws://localhost/allmyfiles/WSHandler.cfm";
At this point this will probably not work, but messages might be helpful for future.
I don't think the handler would work because Tomcat needs to get the request directly... not the handler. A .cfm or .cfc will only handle a single one way request. I order to handle a bidirectional connection, tomcat needs to get a hold of it.
I am attempting to get websockets running on a Windows/IIS/Boncode/Lucee5.1 application. Are websockets supported, and if so, what do I need to do in order to connect them to Lucee? If not, what is it on the roadmap, or is there a workaround? For a workaround, I'm considering connecting to tomcat directly and bypassing IIS, but only for websocket endpoints.