Skip to content
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

[tomcat] Sprint exception with WebSocket #280

Closed
jfarcand opened this issue Apr 12, 2012 · 3 comments
Closed

[tomcat] Sprint exception with WebSocket #280

jfarcand opened this issue Apr 12, 2012 · 3 comments

Comments

@jfarcand
Copy link
Member

@jfarcand jfarcand commented Apr 12, 2012

java.lang.ClassCastException: org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestWrapper cannot be cast to org.apache.catalina.connector.RequestFacade at org.atmosphere.container.Tomcat7AsyncSupportWithWebSocket.service(Tomcat7AsyncSupportWithWebSocket.java:116) at org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework.java:1146)

@lmoreno

This comment has been minimized.

Copy link

@lmoreno lmoreno commented Apr 12, 2012

Replaced org.atmosphere.container.Tomcat7AsyncSupportWithWebSocket line 116 :
RequestFacade facade = (RequestFacade) req.wrappedRequest();

with:
HttpServletRequest hsr = req.wrappedRequest();
while(hsr instanceof HttpServletRequestWrapper)
hsr = (HttpServletRequest) ((HttpServletRequestWrapper) hsr).getRequest();

RequestFacade facade = (RequestFacade) hsr;

@jfarcand

This comment has been minimized.

Copy link
Member Author

@jfarcand jfarcand commented Apr 12, 2012

Integrated. Thanks!

@jfarcand jfarcand closed this Apr 12, 2012
@jfarcand

This comment has been minimized.

Copy link
Member Author

@jfarcand jfarcand commented Apr 12, 2012

Filled in Tomcat

   https://issues.apache.org/bugzilla/show_bug.cgi?id=53067
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.