- Replace bounded elastic schedulers with single thread executors
- Add timeouts to MCP server tests
- Enhance error handling in StdioServerTransport
- Comment out unused PaginatedRequest unmarshalling
- Simplify shutdown logic in StdioServerTransport
Removes custom stream injection capability from StdioServerTransport and
simplifies it to only use System.in/out.
Updates related tests to use System streams instead of piped streams.
- Add isClosing flag to coordinate graceful shutdown
- Synchronize output stream writes to prevent race conditions
- Enhance error handling in stream processing
- Add delay for pending message processing during shutdown
- Improve connection state tracking in tests
- Implement MCP server with async/sync support and builder pattern configuration
- Add Server stdio/SSE transport layers with robust error handling
- Convert McpClient and McpServer to interfaces for better extensibility
- Add sampling capabilities for LLM interactions (text/image)
- Implement dynamic root management and runtime tool management
- Add comprehensive prompt and resource capabilities
- Add support for dynamic root management (add/remove roots at runtime)
Architecture Changes
- Introduce registration records for tools, resources, and prompts
- Improve thread safety with concurrent collections
- Enhance resource template handling
- Implement builder patterns for Server/Client capabilities
- Add support for server capabilities and implementation info
Transport Layer:
- Implement SseServerTransport with SSE endpoints
- Add StdioServerTransport for process-based communication
- Reorganize transport packages for better organization
- Improve transport error handling and shutdown processes
Documentation:
- Add detailed MCP reference documentation
- Include architecture diagrams and API documentation
- Add comprehensive test coverage for all components
- Include sample projects demonstrating stdio/SSE transports
BREAKING CHANGES:
Transport Package Reorganization
- Move StdioClientTransport to o.s.ai.mcp.client.transport
- Move SseClientTransport to o.s.ai.mcp.client.transport
- Move ServerParameters to o.s.ai.mcp.client.transport
- StdioClientTransport.errorHandler changed to private with
setter method Migration: Use setErrorHandler() method
instead of direct field access
API Changes
- Replace static factory methods with builder pattern
- Update ServerCapabilities to use builder pattern
- Make StdioClientTransport.errorHandler private with setter
- Replace rootsListProvider with direct root management
- Remove deprecated static factory methods
Resolves #27,#25,#24,#11
Related to #12
- Adds default logging for tools, resources and prompts change notifications.
- Introduces Utils class with collection and string helper methods.
- Ensures notification handlers are always registered with at least a default logging consumer.
- Add resourcesChangeNotificationHandler and promptsChangeNotificationHandler with non-blocking execution
- Add builder methods for resources and prompts change consumers
- Add test coverage for all notification handlers
- Update documentation to cover all three notification types (tools, resources, prompts)
- Consolidate notification documentation under unified Change Notifications section
- Ensure consistent non-blocking behavior using boundedElastic scheduler
All notification handlers follow the same pattern of non-blocking execution and error handling,
providing a consistent approach to change notifications across the system.
Resolves#20
- Add toolsChangeNotificationHandler with non-blocking consumer execution using boundedElastic scheduler
- Add toolsChangeConsumer builder method to McpClient for easy configuration
- Add comprehensive test coverage for tools change notifications
- Update documentation with tools change notification features and examples
The implementation ensures consumers are executed non-blockingly on the boundedElastic scheduler,
preventing performance impact from blocking implementations while maintaining proper error handling and logging.
Part of #20
- Add roots list capability to allow servers to understand filesystem boundaries
- Move architecture diagram and add detailed documentation for transports and sessions
- Enhance client capabilities with roots and sampling features
- Rename withRequestTimeout to requestTimeout for better API consistency
- Add tests for roots list functionality
Resolves#8
- The core module has been refactored to remove unnecessary abstraction
between the SSE transport and the STDIO transport.
- Tests have been improved and no longer complain about multiple
subscriptions to single-subscriber Sink.
- SSE transport layer is now assuming non-blocking execution and no longer
makes thread hops when not needed.
- Decouple ObjectMapper and error handling from AbstractMcpTransport
and remove later.
Additional improvements:
- Rename transport classes to better reflect client-side role (*ServerTransport -> *ClientTransport)
- Introduce fluent builder pattern for client configuration
- Simplify DefaultMcpSession by removing ObjectMapper dependency
- Move unmarshal responsibility to transport layer
- Update documentation and diagrams to reflect new architecture
- Clean up test implementations
- Add comprehensive documentation for MCP session components in MCP-SESSION.md
- Add logging and error handling in McpAsyncClient
- Update test configurations and dependencies
- Add reactor-netty-http and spring-context test dependencies
Resolves#6
- Add Server-Sent Events (SSE) transport implementation with test coverage
- Add detailed documentation for both SSE and STDIO transports
- Extract common test logic into abstract base classes
- Add testcontainers support for SSE integration tests
- Replace System.out with SLF4J logging
- Externalize dependency versions to properties
- Implement endpoint event handling per MCP spec
- Add message endpoint sink for reliable message routing
- Improve error handling and graceful shutdown
- Update core module README with expanded features and examples
- Add dependency version properties and logging configuration
- Update architecture and class diagrams
Resolves#4
Add overloaded methods for list operations (tools, resources, templates, prompts)
that don't require a cursor parameter, simplifying the API for basic use cases
where pagination is not needed.
- Doubles the default timeout from 10s to 20s in McpAsyncClient
- Updates corresponding timeout values in test classes
- Enables previously disabled async client tests
Add overloaded methods for list operations (tools, resources, templates, prompts)
that don't require a cursor parameter. This simplifies the API for cases where
pagination is not needed.
- Enhance process handling in StdioServerTransport with proper cleanup
- Refactor graceful shutdown across McpSession implementations
- Add proper JSON serialization annotations for Role and LoggingLevel enums
- Fix typo in setInboundMessageHandler method name
- Improve test coverage using StepVerifier
- Add documentation and cleanup code