You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(java): clarify core vs optional transport implementations
- Emphasize that core mcp module includes default STDIO and SSE transport implementations
- Clarify that default implementations don't require external web frameworks
- Mark Spring-specific transport implementations as optional dependencies
Signed-off-by: Christian Tzolov <[email protected]>
Copy file name to clipboardExpand all lines: sdk/java/mcp-client.mdx
+4-3Lines changed: 4 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,9 +15,10 @@ The MCP Client is a key component in the Model Context Protocol (MCP) architectu
15
15
- Prompt system interactions
16
16
- Optional features like roots management and sampling support
17
17
18
-
<Tip>
19
-
The [Spring-AI MCP Client](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-client-boot-starter-docs.html) integration extends the MCP Java SDK to
20
-
provide auto-configuration for MCP client functionality in Spring Boot applications and integrating with Spring AI’s [tool execution framework](https://docs.spring.io/spring-ai/reference/api/tools.html).
18
+
<Tip>
19
+
The core `io.modelcontextprotocol.sdk:mcp` module provides STDIO and SSE client transport implementations without requiring external web frameworks.
20
+
21
+
Spring-specific transport implementations are available as an **optional** dependency `io.modelcontextprotocol.sdk:mcp-spring-webflux` for [Spring Framework](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-client-boot-starter-docs.html) users.
21
22
</Tip>
22
23
23
24
The client provides both synchronous and asynchronous APIs for flexibility in different application contexts.
Copy file name to clipboardExpand all lines: sdk/java/mcp-overview.mdx
+19-14Lines changed: 19 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,18 +22,20 @@ If you're upgrading from 0.7.0, please refer to the [Migration Guide](https://gi
22
22
-[Prompt](https://spec.modelcontextprotocol.io/specification/2024-11-05/server/prompts/) handling and management
23
23
-[Sampling](https://spec.modelcontextprotocol.io/specification/2024-11-05/client/sampling/) support for AI model interactions
24
24
- Multiple transport implementations:
25
-
- Default transports:
25
+
- Default transports (included in core `mcp` module, no external web frameworks required):
26
26
- Stdio-based transport for process-based communication
27
27
- Java HttpClient-based SSE client transport for HTTP SSE Client-side streaming
28
28
- Servlet-based SSE server transport for HTTP SSE Server streaming
29
-
- Spring-based transports:
29
+
-Optional Spring-based transports (convenience if using Spring Framework):
30
30
- WebFlux SSE client and server transports for reactive HTTP streaming
31
31
- WebMVC SSE transport for servlet-based HTTP streaming
32
32
- Supports Synchronous and Asynchronous programming paradigms
33
33
34
-
<Tip>[Spring AI MCP](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-overview.html) extends the MCP Java SDK with Spring Boot integration,
35
-
providing both [Client](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-client-boot-starter-docs.html) and [Server](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-server-boot-starter-docs.html) Boot Starters.
36
-
You can bootstrap your AI Spring applications using the [Spring Initializer](https://start.spring.io/).</Tip>
34
+
<Tip>
35
+
The core `io.modelcontextprotocol.sdk:mcp` module provides default STDIO and SSE client and server transport implementations without requiring external web frameworks.
36
+
37
+
Spring-specific transports are available as optional dependencies for convenience when using the [Spring Framework](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-client-boot-starter-docs.html).
38
+
</Tip>
37
39
38
40
## Architecture
39
41
@@ -80,16 +82,18 @@ The core MCP functionality:
80
82
</dependency>
81
83
```
82
84
83
-
For HTTP SSE transport implementations, add one of the following dependencies:
85
+
The core `mcp` module already includes default STDIO and SSE transport implementations and doesn't require external web frameworks.
86
+
87
+
If you're using the Spring Framework and want to use Spring-specific transport implementations, add one of the following optional dependencies:
84
88
85
89
```xml
86
-
<!-- Spring WebFlux-based SSE client and server transport -->
90
+
<!--Optional: Spring WebFlux-based SSE client and server transport -->
87
91
<dependency>
88
92
<groupId>io.modelcontextprotocol.sdk</groupId>
89
93
<artifactId>mcp-spring-webflux</artifactId>
90
94
</dependency>
91
95
92
-
<!-- Spring WebMVC-based SSE server transport -->
96
+
<!--Optional: Spring WebMVC-based SSE server transport -->
93
97
<dependency>
94
98
<groupId>io.modelcontextprotocol.sdk</groupId>
95
99
<artifactId>mcp-spring-webmvc</artifactId>
@@ -106,15 +110,17 @@ For HTTP SSE transport implementations, add one of the following dependencies:
106
110
}
107
111
```
108
112
109
-
For HTTP SSE transport implementations, add one of the following dependencies:
113
+
The core `mcp` module already includes default STDIO and SSE transport implementations and doesn't require external web frameworks.
114
+
115
+
If you're using the Spring Framework and want to use Spring-specific transport implementations, add one of the following optional dependencies:
110
116
111
117
```groovy
112
-
// Spring WebFlux-based SSE client and server transport
118
+
// Optional: Spring WebFlux-based SSE client and server transport
@@ -169,10 +175,9 @@ Replace the version number with the version of the BOM you want to use.
169
175
The following dependencies are available and managed by the BOM:
170
176
171
177
- Core Dependencies
172
-
-`io.modelcontextprotocol.sdk:mcp` - Core MCP library providing the base functionality and APIs for Model Context Protocol implementation.
173
-
- Transport Dependencies
178
+
-`io.modelcontextprotocol.sdk:mcp` - Core MCP library providing the base functionality and APIs for Model Context Protocol implementation, including default STDIO and SSE client and server transport implementations. No external web frameworks required.
179
+
-Optional Transport Dependencies (convenience if using Spring Framework)
174
180
-`io.modelcontextprotocol.sdk:mcp-spring-webflux` - WebFlux-based Server-Sent Events (SSE) transport implementation for reactive applications.
175
181
-`io.modelcontextprotocol.sdk:mcp-spring-webmvc` - WebMVC-based Server-Sent Events (SSE) transport implementation for servlet-based applications.
176
182
- Testing Dependencies
177
183
-`io.modelcontextprotocol.sdk:mcp-test` - Testing utilities and support for MCP-based applications.
Copy file name to clipboardExpand all lines: sdk/java/mcp-server.mdx
+5-3Lines changed: 5 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,11 +21,13 @@ The MCP Server is a foundational component in the Model Context Protocol (MCP) a
21
21
- Managing concurrent client connections
22
22
- Providing structured logging and notifications
23
23
24
-
<Tip>
25
-
The [Spring-AI MCP Server](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-server-boot-starter-docs.html) integration extends the MCP Java SDK to
26
-
provide auto-configuration for MCP server functionality in Spring Boot applications.
24
+
<Tip>
25
+
The core `io.modelcontextprotocol.sdk:mcp` module provides STDIO and SSE server transport implementations without requiring external web frameworks.
26
+
27
+
Spring-specific transport implementations are available as an **optional** dependencies `io.modelcontextprotocol.sdk:mcp-spring-webflux`, `io.modelcontextprotocol.sdk:mcp-spring-webmvc` for [Spring Framework](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-client-boot-starter-docs.html) users.
27
28
</Tip>
28
29
30
+
29
31
The server supports both synchronous and asynchronous APIs, allowing for flexible integration in different application contexts.
0 commit comments