Cannot establish WebSocket connection

I want to enable a websocket connection. My setup is:

CF-domain → OTHER-domain (CNAME) → ROUTER → PRIVATE-MQ-server

To establish a connection via CF-domain I get “org.eclipse.paho.client.mqttv3.MqttException: Timed out waiting for a response from the server”

When I establish a connection via OTHER-domain everything works fine. Therefore port-forwarding etc. should be fine. Same behaviour for WS as well as WSS connections.

WebSockets-Feature is enabled on CF. Since CF means “No additional configuration is required to send WebSockets traffic through Cloudflare.” I really wonder where the problem is. Has anyone an idea to track the issue down? Help is very much appreciated!

solution was to add another CNAME and disable proxy-mode for this record: MQTT connection over Proxied DNS