-
Notifications
You must be signed in to change notification settings - Fork 37.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot upgrade to WebSocket connection when using Spring 4 WebSocket with embedded Tomcat 8.0.0-RC1 [SPR-10841] #15467
Comments
Rossen Stoyanchev commented Have you tried the standalone version? I've been using that with both 8.0 RC1 and Tomcat trunk so it would be good to confirm if this is due to the standalone vs embedded version, or something specific in your code that's triggering it. |
Sergey Shcherbakov commented Hi Rossen, The NPE is caused by the webSocketContainer which is not getting passed to the preInit() method. |
Rossen Stoyanchev commented It sounds SCI scanning is not enabled. It's what underlies the new WebSocket support so if not enabled, there is no ServerContainer. You might want to see https://issues.apache.org/bugzilla/show_bug.cgi?id=55312. |
Sergey Shcherbakov commented I have found the way to fix the issue locally.
The WS upgrade and communication works perfectly after that. PS: The spring-boot team might be interested in switching this customization on by default. |
Rossen Stoyanchev commented /cc Dave Syer |
Rossen Stoyanchev commented You might want to open an issue with Spring Boot. Doesn't seem to be anything we can fix in the core Spring framework. |
I Face the some problem , but I can't do the same configuration in the solution since it's depressed in version 2+ , Any Help please |
Sergey Shcherbakov opened SPR-10841 and commented
I'm building a Spring 4 driven application with an embedded Tomcat 8 and SockJS to support WebSocket clients.
The latest 4.0.0.BUILD-SNAPSHOT (14.08.2013) as well as 4.0.0.M2 cannot upgrade the incoming HTTP connection to WS with the following exception (for the snapshot version):
Affects: 4.0 M2
The text was updated successfully, but these errors were encountered: