spring-ai icon indicating copy to clipboard operation
spring-ai copied to clipboard

No static resource sse.

Open X-TAN opened this issue 7 months ago • 2 comments
trafficstars

No static resource sse.

Bug description

使用cursor 连接 webflux mcp 服务器,在解析 /see 请求时发生了 404 NOT_FOUND. Image Image

Environment

Spring AI 1.0.0-M6 Java version 17 MACOS 15.3.2 (24D81)

Steps to reproduce

  1. 使用 cursor 作为 mcp-client

  2. 使用 spring-ai-mcp-server-webflux-spring-boot-starter 构建 mcp-server

  3. 修复 Caused by: com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "tools" 问题

        @Bean
        @ConditionalOnMissingBean
        public WebFluxSseServerTransport webFluxTransport(McpServerProperties serverProperties) {
            ObjectMapper objectMapper = new ObjectMapper();
            objectMapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
            return new WebFluxSseServerTransport(objectMapper, serverProperties.getSseMessageEndpoint());
    
    
  4. 使用 cursor 与 mcp-server 连接。

当修复了 Caused by: com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: Unrecognized field "tools" 后还是无法与 cursor 建立正常通讯。

X-TAN avatar Mar 28 '25 08:03 X-TAN