整合springcloud和gateway
报错:
2024-06-06 16:28:22.116 ERROR [service-gateway,,,] 22452 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter :
***************************
APPLICATION FAILED TO START
***************************
Description:
Parameter 0 of method modifyResponseBodyGatewayFilterFactory in org.springframework.cloud.gateway.config.GatewayAutoConfiguration required a bean of type 'org.springframework.http.codec.ServerCodecConfigurer' that could not be found.
Action:
Consider defining a bean of type 'org.springframework.http.codec.ServerCodecConfigurer' in your configuration.
解决方法:
去掉spring相关的web依赖
因为gateway依赖中包含了webflux依赖会冲突
去掉即可