-
Notifications
You must be signed in to change notification settings - Fork 5.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
Can not start spring application with webflux and websocket for ObjectPostProcessor is needed. #5932
Comments
Thanks for the report. It almost sounds as though you are using the imperative (non-reactive) web socket support. Can you provide a complete stacktrace? Perhaps a small sample project? |
Thanks for your response. I tried again and found that it works well while using dependency of 'org.springframework:spring-websocket' instead of 'org.springframework.boot:spring-boot-starter-websocket'. In deed, spring-boot-starter-websocket depends on 'org.springframework:spring-webmvc' to case this issue. We can exclude 'org.springframework:spring-webmvc' to avoid it. I suggest that spring-boot-starter-websocket does not depends on 'org.springframework:spring-webmvc' or there is another spring-boot-starter-webflux-websocket which depends on 'org.springframework:spring-webflux' instead of 'org.springframework:spring-webmvc'. |
Perhaps because in my gradle dependencies 'spring-boot-starter-websocket' appears before 'org.springframework:spring-webflux'. It works strangely if there are both spring-webmvc and spring-webflux in the classpath. |
Thanks for the additional details! Can you please create a sample and post this to spring-boot? They are in charge of the autoconfiguraiton and the starter poms. When you create that ticket, can you please provide a link here? |
14810 |
Thanks that works. I'm closing this issue as there is nothing we can do from the Spring Security side of things |
Summary
***************************
APPLICATION FAILED TO START
***************************
Description:
A component required a bean of type 'org.springframework.security.config.annotation.ObjectPostProcessor' that could not be found.
Action:
Consider defining a bean of type 'org.springframework.security.config.annotation.ObjectPostProcessor' in your configuration.
Actual Behavior
Fail to start. BUT it works well without dependency of 'org.springframework.boot:spring-boot-starter-websocket'
Configuration
Version
spring boot 2.0.5.RELEASE
io.spring.platform:platform-bom:Cairo-SR4
org.springframework.cloud:spring-cloud-dependencies:Finchley.SR1
Sample
The text was updated successfully, but these errors were encountered: