Closed Marcell0oo0 closed 2 months ago
Hi, Thanks for raising this issue. Unfortunately, this repo is for reporting issues with the documentation. You seem to be requesting a new feature. The best place to do this is on the Community Ideas page. There you can get support for your ideas from other members of the community, and they can be picked up by the development teams. I suggest that you put this request there so that it gains traction from the community.
Thanks for your suggestions for making Mendix better. Yours Mark van Ments.
Page link: websockets
Document link: websockets-in-runtime.md
My Issue
In some communication protocol, which is based on WebSocket, we need to read and write the opening handshake header. In Java we can do this with modifyHandshake
public void modifyHandshake(ServerEndpointConfig sec, HandshakeRequest request, HandshakeResponse response)
For example there is a communication protocol, where there is different versions, and the client writes in the header, what versions they are accept. So we need to read it form the header, for example (MyProtocolVersion : 3.4, 4.5 ), and respond (MyProtocolVersion : 3.4) or (MyProtocolVersion : 4.5)
In the future is it possible that we will have access to it?
My suggestion:
Mendix will still handle the headers, except the "Other headers", so we can read it and do something in Java then write the "Other headers", and based on the value, say no to the client, so no websocket connection will made. And I also want to read the URI during the handshake, because in the protocol that I want to implement, the clients put his ID after the "ws://.../my-endpoint" like this ws://.../my-endpoint/ClientID