link #115926 Upgrade MCP SDK fork to upstream v0.18.2 for streamable http + re-apply Veoci customizations (v1.4.0) by parth-iprime · Pull Request #7 · GreywallSoftware/java-sdk · GitHub
Skip to content

link #115926 Upgrade MCP SDK fork to upstream v0.18.2 for streamable http + re-apply Veoci customizations (v1.4.0) #7

Merged
rhishirajnema merged 222 commits into
masterfrom
ticket/parth/115926
Jun 25, 2026
Merged

link #115926 Upgrade MCP SDK fork to upstream v0.18.2 for streamable http + re-apply Veoci customizations (v1.4.0) #7
rhishirajnema merged 222 commits into
masterfrom
ticket/parth/115926

Conversation

@parth-iprime

@parth-iprime parth-iprime commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Summary

Upgrades the fork's base from the ~0.10-era line to upstream v0.18.2 (top of the pre-1.0 line — adds Streamable HTTP, keeps SSE and the in-repo WebMVC transport, no Spring AI split) and re-applies all Veoci customizations on top. Fork artifact version is set to 1.4.0.

Motivation and Context

We need Streamable HTTP support alongside SSE. Streamable HTTP landed upstream in 0.11.0; 0.18.2 is the newest pre-1.0 release, so we get it with minimal disruption to our vendored WebMVC transport and auth customizations (the 1.x/2.x lines move the WebMVC transport out to Spring AI and decouple Jackson, which would be a larger change). Ref #115926.

How Has This Been Tested?

mvn clean install passes on the full reactor (JDK 21).

Breaking Changes

  • Fork artifact version bumped 1.3.01.4.0; downstream (soschat) must update its io.modelcontextprotocol.sdk:mcp dependency to 1.4.0.
  • Core module renamed upstream mcpmcp-core; mcp is now a thin aggregator (still resolvable).

Types of changes

  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling

Additional context

Re-applied Veoci customizations (original authors preserved):

Build/publish config restored: veoci-m2-repo repository, scpexe distributionManagement, and the wagon-ssh-external extension. The upstream central-publishing plugin remains opt-in under -Prelease, so mvn deploy targets m2.veoci.com.

jitokim and others added 30 commits May 8, 2025 11:31
…ol#181)

The isInitialized method is present in McpAsyncClient and needs to be
mirrored in McpSyncClient.

Signed-off-by: jitokim <pigberger70@gmail.com>
Before this fix the execution of the maven surefire
plugin with Java 21 logged warnings that mockito should be added as
a java agent, because the self-attaching won't be supported in future
java releases.
In Java 24 the test just broke.

This problem is solved by modifying the pom.xml of the parent and doing
this changes:

* Adding mockito as a java agent.
* Removing the surefireArgLine from the properties. This can be
added back when it's needed (for example when JaCoCo will be used).

Furthermore, the pom.xml in the mcp-spring-* modules now have
the byte-buddy dependency included, as the test would otherwise break
when trying to mock McpSchema#CreateMessageRequest.

Fixes modelcontextprotocol#187

Co-authored-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
…ocol#237)

Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
Implement elicitation capabilities allowing servers to request additional information
from users through clients during interactions. This feature provides a standardized
way for servers to gather necessary information dynamically while clients maintain
control over user interactions and data sharing.

- Add ElicitRequest and ElicitResult classes to McpSchema
- Implement elicitation handlers in client classes
- Add elicitation capabilities to server exchange classes
- Add tests for elicitation functionality with various scenarios
An implementation of Streamable HTTP Client with WebFlux WebClient.
Aside from implementing the specification, several improvements have been incorporated throughout the client-side of the architecture.

The changes cover:
- resilience tests using toxiproxy in testcontainers
- integration tests using updated everything-server with streamableHttp support
- improved logging
- session invalidation handling (both transport session and JSON-RPC concept of session)
- implicit initialization and burst protection (in case of concurrent `Mcp(Sync|Async)Client` use
- more logging, e.g. stdio process lifecycle logs

Related modelcontextprotocol#72, modelcontextprotocol#273, modelcontextprotocol#253, modelcontextprotocol#107, modelcontextprotocol#105

Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
- Replace single documentation link with organized list of sections
- Add direct links to Features, Architecture, Dependencies, Client, and Server docs
- Improve navigation and discoverability of specific documentation topics

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
- Add AudioContent record class implementing Annotated and Content interfaces
- Update Content sealed interface to permit AudioContent
- Add audio type handling in Content.type() method
- Include AudioContent in JsonSubTypes annotation for polymorphic deserialization
- Add comprehensive tests for AudioContent serialization and deserialization
- Update error message test to include audio in known type ids

https://github.com/modelcontextprotocol/modelcontextprotocol/blob/c87a0da6d8c2436d56a6398023c80b0562224454/schema/2025-03-26/schema.ts#L987-L1009
Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
…extprotocol#255)

- Add testSampling() methods to AbstractMcpAsyncClientTests and AbstractMcpSyncClientTests

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>

Co-authored-by: Christian Tzolov <christian.tzolov@broadcom.com>
- Add explicit Void type parameter to Mono.defer() call
- Chain .then() to Mono.delay() to ensure consistent Mono<Void> return type

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
…extprotocol#242)

Updates all Content types to represent annotations as nested objects
instead of directly on the content itself.

- Refactor TextContent, ImageContent, and EmbeddedResource to use Annotations object instead of separate audience/priority fields
- Add backward-compatible deprecated methods for audience() and priority() accessors
- Add parameterized tests for message annotations across different message types (success, error, debug)
- Test both text and image content annotations with proper priority and audience validation

This brings the implementation in line with the content types as modeled by the specification:
https://github.com/modelcontextprotocol/modelcontextprotocol/blob/c87a0da6d8c2436d56a6398023c80b0562224454/schema/2025-03-26/schema.json#L1970-L1973
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
- Implement comprehensive resource content validation for text/plain and application/octet-stream MIME types
- Validate resource count expectations (10 resources)
- Add elicitation capability testing with ElicitRequest/ElicitResult support
- Clean up unused imports (ObjectMapper, ImageFromDockerfile)

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
…textprotocol#331)

The size field helps hosts display file sizes and estimate context window usage.

- Add size parameter to Resource record for tracking raw content size in bytes
- Implement Builder pattern for Resource construction with validation
- Add deprecated constructor for backwards compatibility
- Add tests for builder pattern and field validation

Resolves modelcontextprotocol#330

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
- Add string values and JsonCreator method to StopReason enum
- Map unknown stop reason values to UNKNOWN constant for forward compatibility
- Add test coverage for unknown stop reason deserialization

Spec: https://github.com/modelcontextprotocol/modelcontextprotocol/blob/f5ccad944fdf2b7d9cc70cf817f66ca5a8aa03a4/schema/2024-11-05/schema.ts#L807

Resolves modelcontextprotocol#328
…#306)

This change enhances the client API by providing both paginated access for fine-grained
control and convenience methods for retrieving complete result sets automatically.

- Implement "list all" methods that automatically handle pagination using expand/reduce operations
- Replace null parameters with McpSchema.FIRST_PAGE constant for better readability
- Add tests for both paginated and "list all" functionality
- Update method javadocs to clarify pagination behavior
- Maintain backward compatibility

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
…odelcontextprotocol#333)

- Add .copy() call before modifying requestBuilder in FlowSseClient
- Add .copy() call before modifying requestBuilder in HttpClientSseClientTransport
- Prevents unintended mutations of shared builder instances
…protocol#313)

Signed-off-by: Sun Yuhan <sunyuhan1998@users.noreply.github.com>
…otocol#334)

- Move session setup, completion, and error callbacks into doInitialize method
- Rename variables in McpClientSession for better clarity (sink -> pendingResponseSink/deliveredResponseSink)

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
This enables servers to notify clients when specific resources are updated,
allowing clients to react to individual resource changes rather than just
list changes.

- Add ResourcesUpdatedNotification schema with uri field
- Add METHOD_NOTIFICATION_RESOURCES_UPDATED constant
- Implement notifyResourcesUpdated() methods in McpAsyncServer and McpSyncServer
- Add client-side support for resource update consumers and handlers
- Client automatically reads updated resource content when notification received
- Add tests for both async and sync server implementations

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
…ontextprotocol#339)

* feat: Propagate Context to eager connect via McpClientSession

In order to allow the initial connection to have contextual information
in the reactive chain, the McpClientSession should be able to transform
the McpClientTransport#connect result, e.g. to attach Context items.
This change introduces a new constructor for sessions that makes it
possible.

Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>

---------

Signed-off-by: Dariusz Jędrzejczyk <dariusz.jedrzejczyk@broadcom.com>
…tocol#336)

- Add nextCursor field to ListRootsResult for cursor-based pagination
- Implement automatic pagination in McpAsyncServerExchange.listRoots()
 - Automatically fetches and combines all pages into single result
 - Refactor McpAsyncServerExchange.listRoots() to return Collections.unmodifiableList
- Update tests to verify pagination functionality

- Add test suite for McpAsyncServerExchange covering:
  - listRoots() pagination scenarios and edge cases
  - Logging notification with level filtering
  - Elicitation creation with various capabilities
  - Message creation with sampling capabilities
  - Error handling and validation scenarios
  - Verify sendNotification calls in logging notification tests
  - Verify sendRequest is never called when capabilities are missing

Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
tzolov and others added 19 commits February 19, 2026 10:52
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
- Backport modelcontextprotocol#943

Signed-off-by: Daniel Garnier-Moiroux <git@garnier.wf>
Signed-off-by: Daniel Garnier-Moiroux <git@garnier.wf>
Signed-off-by: Daniel Garnier-Moiroux <git@garnier.wf>
Signed-off-by: Daniel Garnier-Moiroux <git@garnier.wf>
Signed-off-by: Daniel Garnier-Moiroux <git@garnier.wf>
Signed-off-by: Christian Tzolov <christian.tzolov@broadcom.com>
* Support setting Spring authentication object in McpServerSession

* return session and not exchange

(cherry picked from commit 3755339)
…o, distributionManagement, wagon-ssh-external)
@parth-iprime

parth-iprime commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator Author

@parth-iprime

Copy link
Copy Markdown
Collaborator Author

Hey @rhishirajnema , need a code review pass for the changes you did previously for sse . Perhaps normandy can help ?

@parth-iprime

Copy link
Copy Markdown
Collaborator Author

@rhishirajnema rhishirajnema merged commit 7f007e3 into master Jun 25, 2026
8 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.