Websockets on Tomcat 8 + IIS 8 with ARR 3 are not working
I had the same Problem. The Workaround is to override the Websockets compression handling header from the Client with ARR. IE dosen't force or try Websocket Compression but Chrome and Firefox will issue the Request with a Header "Sec-WebSocket-Extensions: permessage-deflate".
Since I could not influence my NodeJS backend server, I had to solve this in the ARR.
Have a Look at this article.
https://community.home-assistant.io/t/solved-access-via-iis-reverse-proxy-died-after-upgrade-to-0-58/34408
It worked for me.
After the Modifications the Header was overriden with a blank value in my inbound Rewrite Rule and ARR had no Problems to handle Websocket Requests and Responses because they were not compressed by this and ARR could handle them with the activated Websockets module in IIS.
I have discovered the solution, although it is not as satisfying as I wish it was.
In our project's pom.xml
we had spring-core:4.2.5
but spring-websocket
and spring-messaging
were 4.1.6
. The version mismatch was causing some issues clearly.
Setting -Dorg.apache.tomcat.websocket.DISABLE_BUILTIN_EXTENSIONS=true
in the Tomcat startup options when the versions were mismatched had no effect. Setting that JVM option when the versions were the same worked as expected.
The 101
response now does not contain permessage-deflate
and websockets are able to connect with no issues through IIS. Our application does not send a lot of data through the sockets so we were OK making this tradeoff.