springcloud-gateway自带web依赖,如果引用spring-boot-starter-web会报如下错误:
gateway yml配置:
spring: cloud: gateway: discovery: locator: enabled: true lower-case-service-id: true #服务名称支持小写 routes: - id: hbistc-ums uri: lb://hbistc-ums predicates: - Path=/ums/** filters: - StripPrefix=1 globalcors: cors-configurations: '[/**]': allowCredentials: true #允许访问携带token allowedOrigins: "*" allowedHeaders: "*" allowedMethods: "*"