https://github.com/dreamcenter/springboot-mcpserver-junit
A template idea project by springboot、mcp、junit. Available for both stdio and sse mode.
https://github.com/dreamcenter/springboot-mcpserver-junit
junit mcp spring-boot sse stdio
Last synced: 3 months ago
JSON representation
A template idea project by springboot、mcp、junit. Available for both stdio and sse mode.
- Host: GitHub
- URL: https://github.com/dreamcenter/springboot-mcpserver-junit
- Owner: dreamcenter
- Created: 2025-03-21T09:39:05.000Z (3 months ago)
- Default Branch: master
- Last Pushed: 2025-03-22T06:41:59.000Z (3 months ago)
- Last Synced: 2025-03-22T07:27:05.679Z (3 months ago)
- Topics: junit, mcp, spring-boot, sse, stdio
- Language: Java
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Springboot + MCP + JUnit 模板项目
使用springboot快速构建一个mcp项目,项目支持 JUNIT单元测试。
模式支持: **STDIO** 和 **SSE**
解说视频: [BV1qUXkYRE6C](https://www.bilibili.com/video/BV1qUXkYRE6C)
### 开发环境
- 开发IDE: IDEA
- java版本: JAVA17 (Spring官方要求必须java17+)
- maven版本: 3.8.1 (太高引入项目时可能报错,请选择适当版本)### 参考文档资料
1. [MCP官网](https://modelcontextprotocol.io/quickstart/server)
2. [Spring官网](https://docs.spring.io/spring-ai/reference/api/mcp/mcp-server-boot-starter-docs.html)### 客户端测试方案
对于STDIO客户端配置方式:
```text
命令:java
参数:
-jar
-Dspring.ai.mcp.server.stdio=true
AbsolutePath/**/xxx.jar
```对于SSE客户端配置方式:
```text
SSE地址填写如下链接即可
http://主机地址:端口/sse
```