Spring AI MCP 0.4.0 (Milestone) Released

Releases | Christian Tzolov | January 04, 2025 | ...

We're pleased to announce Spring AI MCP 0.4.0 milestone release.

Repository Configuration

Add this Spring milestone repository to your POM:

<repositories>
  <repository>
    <id>spring-milestones</id>
    <name>Spring Milestones</name>
    <url>https://repo.spring.io/libs-milestone-local</url>
    <snapshots>
      <enabled>false</enabled>
    </snapshots>
  </repository>
</repositories>

Major Features

Reference documentation: https://docs.spring.io/spring-ai-mcp/reference/overview.html

Enhanced Roots Management

  • Implemented proper ListRootsResult wrapping in async client
  • Added listRoots methods in server components
  • Implemented roots change notification handling in async server
  • Added roots integration tests including async notifications
  • Added support for roots change notification with single and multiple consumers
  • Improved robustness of root addition/removal scenarios

Improved Architecture & Documentation

  • Introduced ClientMcpTransport and ServerMcpTransport marker interfaces
  • Updated client/server implementations with appropriate transport interfaces
  • Reorganized documentation structure for better clarity
  • Relocated documentation images to mcp-docs/antora directory
  • Updated README files with links to online documentation

Server-Side Capabilities

  • Added createMessage method to McpAsyncServer and McpSyncServer for LLM sampling
  • Implemented client-side sampling features in the Model Context Protocol (MCP) server
  • Enhanced server info implementation with default builder options

Bug Fixes & Improvements

  • Fixed potential NullPointerException in toolsListRequestHandler when handling null params
  • Improved error handling for uninitialized clients and missing capabilities
  • Enhanced test coverage across multiple components

Technical Improvements

  • Added structured logging support with configurable severity levels (DEBUG to EMERGENCY)
  • Implemented logging message notifications
  • Added logging consumers for client-side log handling
  • Extended test coverage for logging functionality

Notes

  • Documentation has been updated to reflect new features and improvements
  • Several architectural improvements have been made to enhance maintainability

Get the Spring newsletter

Stay connected with the Spring newsletter

Subscribe

Get ahead

VMware offers training and certification to turbo-charge your progress.

Learn more

Get support

Tanzu Spring offers support and binaries for OpenJDK™, Spring, and Apache Tomcat® in one simple subscription.

Learn more

Upcoming events

Check out all the upcoming events in the Spring community.

View all