Model Context Protocol (MCP) servers can significantly enhance your AI coding workflow by providing high-value context, feedback, and automation capabilities.
MCP servers extend your AI assistant's capabilities by providing:
- Real-time application monitoring (Spring Boot logs, errors, health)
- Codebase indexing and semantic search (faster code navigation)
- Long-term memory storage (context across sessions)
- Build tool integration (Gradle, npm dependency management)
- Design & architecture planning (UML diagrams, symbolic representations)
- Database management (PostgreSQL operations and migrations)
- Frontend development (Storybook, React component management)
To install all requested MCP servers, run:
# Core servers
npm install -g @code-index/mcp-server @aakarsh-sasi/memory-bank-mcp
# Build tools
npm install -g @gradle/develocity-mcp-server @antigravity/npm-plus-mcp @antigravity/spring-initializr-mcp
# Design tools
npm install -g @antoinebou12/uml-mcp @playbooks/ai-diagram-prototype-generator @squirrelogic/mcp-architect
# Docker
npm install -g @modelcontextprotocol/server-docker
# Database
npm install -g @henkdz/postgresql-mcp-server
# Frontend (project dependency)
npm install --save-dev @storybook/addon-mcp
# Python server
pip install logic-lm-mcp-serverThen configure in Cursor Settings → Features → MCP (see complete configuration below).
- Code Index: Reduces token usage by 60-80% for code queries
- Memory: Eliminates redundant context (saves 20-40% tokens)
- Actuator: Targeted log queries vs. full file reads (saves 70-90% tokens)
- Code Index: 10x faster code search
- Maven Tools: Instant dependency analysis vs. manual research
- Memory: Instant context retrieval vs. re-explaining
- Real-time monitoring: Immediate error detection
- Context continuity: Maintains project knowledge across sessions
- Automated analysis: Dependency and security insights
Purpose: Codebase indexing and semantic search
Benefits:
- Index entire codebase for fast semantic search
- Multi-language support (Java, TypeScript, JavaScript, etc.)
- Reduces token usage by providing precise code context
- Faster code navigation and understanding
Installation:
# Install via npm
npm install -g @code-index/mcp-server
# Or clone from GitHub
git clone https://github.com/ViperJuice/Code-Index-MCP.git
cd Code-Index-MCP
npm install
npm run buildConfiguration (add to Cursor MCP settings):
{
"mcpServers": {
"code-index": {
"command": "npx",
"args": ["-y", "@code-index/mcp-server"],
"env": {
"CODE_INDEX_PATH": "./src"
}
}
}
}Repository: https://github.com/ViperJuice/Code-Index-MCP
Purpose: Long-term memory storage and retrieval
Benefits:
- Store context across AI sessions
- Semantic search over past conversations and decisions
- Maintain project history and patterns
- Reduces redundant explanations
Installation:
# Option 1: Memory MCP Server
npm install -g @metorial/mcp-index
# Option 2: Memory Bank MCP (alternative)
npm install -g @aakarsh-sasi/memory-bank-mcpConfiguration (Memory MCP):
{
"mcpServers": {
"memory": {
"command": "npx",
"args": ["-y", "@metorial/mcp-index"],
"env": {
"MEMORY_STORAGE_PATH": "./.mcp-memory"
}
}
}
}Configuration (Memory Bank MCP):
{
"mcpServers": {
"memory-bank": {
"command": "npx",
"args": [
"-y",
"@aakarsh-sasi/memory-bank-mcp",
"--mode",
"code",
"--path",
".",
"--folder",
".memory-bank"
]
}
}
}Repositories:
- Memory: https://github.com/metorial/mcp-index
- Memory Bank: https://github.com/aakarsh-sasi/memory-bank-mcp
Purpose: Gradle and Maven dependency analysis
Benefits:
- Instant dependency insights (versions, vulnerabilities, age)
- Bulk dependency operations
- Build optimization suggestions
- Reduces manual dependency research
Installation:
# Install via npm
npm install -g @maven-tools/mcp-serverConfiguration:
{
"mcpServers": {
"maven-tools": {
"command": "npx",
"args": ["-y", "@maven-tools/mcp-server"],
"env": {
"GRADLE_PROJECT_PATH": "."
}
}
}
}Purpose: Spring Boot project generation and configuration
Benefits:
- Generate Spring Boot projects via natural language
- Add dependencies automatically
- Configure project structure
- Useful for creating new modules or microservices
Installation:
npm install -g @antigravity/spring-initializr-mcpConfiguration:
{
"mcpServers": {
"spring-initializr": {
"command": "npx",
"args": ["-y", "@antigravity/spring-initializr-mcp"]
}
}
}Repository: https://antigravity.codes/mcp/spring-initializr
Purpose: Language-agnostic symbolic representations for design and architecture planning
Benefits:
- Generates UML diagrams (class, sequence, activity, use case) from natural language
- Supports PlantUML, Mermaid, and Kroki diagram formats
- Creates LLM-friendly, language-agnostic design references
- Independent of specific code implementation
- Perfect for architecture planning before coding
Installation:
npm install -g @antoinebou12/uml-mcpOr clone and build:
git clone https://github.com/antoinebou12/uml-mcp.git
cd uml-mcp
npm install
npm run buildConfiguration:
{
"mcpServers": {
"uml-mcp": {
"command": "npx",
"args": ["-y", "@antoinebou12/uml-mcp"]
}
}
}Repository: https://github.com/antoinebou12/uml-mcp
Purpose: AI-generated architecture diagrams and prototypes
Benefits:
- Generates architecture diagrams from natural language descriptions
- Creates flowcharts and mobile app prototypes
- Specialized prompt templates for system architecture
- Multiple AI provider support (ZhipuAI, OpenAI, Gemini)
- Visual design planning and quick iteration
Installation:
npm install -g @playbooks/ai-diagram-prototype-generatorConfiguration:
{
"mcpServers": {
"ai-diagram-generator": {
"command": "npx",
"args": ["-y", "@playbooks/ai-diagram-prototype-generator"],
"env": {
"OPENAI_API_KEY": "your-openai-key-here"
}
}
}
}Setup: Requires an OpenAI, ZhipuAI, or Gemini API key
Website: https://playbooks.com/mcp/ai-diagram-prototype-generator
Purpose: Docker container and image management
Benefits:
- List, start, stop, and manage Docker containers
- Build and manage Docker images
- View container logs and inspect containers
- Manage Docker Compose services
- Essential for containerized development workflows
Installation:
npm install -g @modelcontextprotocol/server-dockerOr:
npm install -g docker-mcp-serverConfiguration:
{
"mcpServers": {
"docker": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-docker"]
}
}
}Note: Requires Docker to be installed and running. The server communicates with the Docker daemon.
Repository: Check npm for available Docker MCP server packages
Purpose: Monitor Spring Boot application logs, health, and metrics
Benefits:
- Real-time log access and filtering
- Health endpoint monitoring
- Error tracking and analysis
- Metrics and performance data
- Significantly reduces token usage by providing targeted log queries
Setup: Since there isn't a ready-made Spring Boot Actuator MCP server, you can create a custom one or use a generic HTTP MCP server.
Option 1: Use Generic HTTP MCP Server
npm install -g @modelcontextprotocol/server-httpConfiguration:
{
"mcpServers": {
"spring-actuator": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-http"],
"env": {
"ACTUATOR_BASE_URL": "http://localhost:8080/actuator",
"ACTUATOR_USERNAME": "admin",
"ACTUATOR_PASSWORD": "admin"
}
}
}
}Option 2: Create Custom Server (see Custom Implementation section below)
Spring Boot Configuration (enable Actuator endpoints):
# application.yml
management:
endpoints:
web:
exposure:
include: health,info,metrics,loggers,logfile
endpoint:
health:
show-details: always
loggers:
enabled: true
logfile:
enabled: true
external-file: ./logs/application.logInstallation:
npm install -g @gradle/develocity-mcp-serverSetup:
- Sign up for Develocity at https://ge.gradle.com (free tier available)
- Generate an API key from your Develocity dashboard
- Add the API key to your MCP configuration
Documentation: https://docs.gradle.com/develocity/mcp-server/
Installation (Option 1 - Build from source):
# Clone the Spring AI examples repository
git clone https://github.com/spring-projects/spring-ai.git
cd spring-ai/spring-ai-samples/mcp-server
./mvnw clean package
# The JAR will be in target/spring-ai-mcp-server-*.jarInstallation (Option 2 - Use Spring Boot Starter):
Add to your pom.xml or build.gradle:
<dependency>
<groupId>org.springframework.ai</groupId>
<artifactId>spring-ai-starter-mcp-server</artifactId>
<version>1.0.0</version>
</dependency>Documentation: https://docs.spring.io/spring-ai/reference/
Note: This server is embedded in Spring Tools 5 IDE. For Cursor integration:
Installation:
- Install Spring Tools 5 (STS) or use the embedded version
- The MCP server runs on SSE endpoint:
http://localhost:50627/sse - Configure as SSE type in Cursor (not stdio)
Documentation: https://spring.io/blog/2025/12/04/towards-spring-tools-5-part3
Installation:
npm install -g @antigravity/npm-plus-mcpWebsite: https://antigravity.codes/mcp/npm-plus
Installation:
npm install -g @antigravity/spring-initializr-mcpAlternative (Native binary):
# Download from releases
# https://github.com/hpalma/springinitializr-mcp/releases
# Extract and use the binary for your platformWebsite: https://antigravity.codes/mcp/spring-initializr
Installation (Python required):
pip install logic-lm-mcp-serverOr from source:
git clone https://github.com/your-repo/logic-lm-mcp-server.git
cd logic-lm-mcp-server
pip install -r requirements.txtPyPI: https://pypi.org/project/logic-lm-mcp-server/
Note: Requires Python 3.8+ and Clingo for ASP solving
Installation:
npm install -g @squirrelogic/mcp-architectOr:
npm install -g mcp-architectWebsite: https://www.mcp.bar/server/squirrelogic/mcp-architect
Installation:
npm install -g @henkdz/postgresql-mcp-serverOr:
npm install -g postgresql-mcp-serverSetup: Configure database connection via environment variables
Website: https://www.mcpnow.io/en/server/postgresql-database-management-henkdz-postgresql-mcp-server
Installation (as Storybook addon):
npm install --save-dev @storybook/addon-mcpConfiguration (in .storybook/main.js or .storybook/main.ts):
export default {
addons: [
'@storybook/addon-mcp',
],
};Note: The MCP server runs within Storybook when it's started. Configure as SSE type pointing to http://localhost:6006/mcp (or your Storybook port).
Documentation: https://storybook.js.org/addons/@storybook/addon-mcp
Here's the complete configuration file for Cursor with all requested MCP servers:
{
"mcpServers": {
"code-index": {
"command": "npx",
"args": ["-y", "@code-index/mcp-server"],
"env": {
"CODE_INDEX_PATH": "./src"
}
},
"memory": {
"command": "npx",
"args": ["-y", "@aakarsh-sasi/memory-bank-mcp", "--mode", "code", "--path", ".", "--folder", ".memory-bank"]
},
"develocity": {
"command": "npx",
"args": ["-y", "@gradle/develocity-mcp-server"],
"env": {
"DEVELOCITY_URL": "https://ge.gradle.com",
"DEVELOCITY_API_KEY": "your-api-key-here"
}
},
"spring-ai": {
"command": "java",
"args": ["-jar", "path/to/spring-ai-mcp-server.jar"],
"env": {
"SPRING_PROFILES_ACTIVE": "mcp"
}
},
"spring-tools-5": {
"type": "sse",
"url": "http://localhost:50627/sse"
},
"npm-plus": {
"command": "npx",
"args": ["-y", "@antigravity/npm-plus-mcp"]
},
"spring-initializr": {
"command": "npx",
"args": ["-y", "@antigravity/spring-initializr-mcp"]
},
"uml-mcp": {
"command": "npx",
"args": ["-y", "@antoinebou12/uml-mcp"]
},
"ai-diagram-generator": {
"command": "npx",
"args": ["-y", "@playbooks/ai-diagram-prototype-generator"],
"env": {
"OPENAI_API_KEY": "your-openai-key-here"
}
},
"docker": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-docker"]
},
"logic-lm": {
"command": "python",
"args": ["-m", "logic_lm_mcp_server"],
"env": {
"LOGIC_LM_MODEL_PATH": "./models"
}
},
"architect": {
"command": "npx",
"args": ["-y", "@squirrelogic/mcp-architect"]
},
"postgresql": {
"command": "npx",
"args": ["-y", "@henkdz/postgresql-mcp-server"],
"env": {
"POSTGRES_HOST": "localhost",
"POSTGRES_PORT": "5432",
"POSTGRES_DB": "your_database",
"POSTGRES_USER": "your_user",
"POSTGRES_PASSWORD": "your_password"
}
},
"storybook": {
"type": "sse",
"url": "http://localhost:6006/mcp"
}
}
}-
Spring Tools 5: Uses SSE (Server-Sent Events) instead of stdio. Ensure Spring Tools 5 is running and the MCP server is enabled.
-
Storybook: Uses SSE endpoint. Ensure Storybook is running (
npm run storybook) and the addon is configured in your Storybook setup. -
Spring AI: Requires building the JAR file first (see installation instructions above). Update the path to your actual JAR location.
-
Environment Variables:
- Replace
your-api-key-herewith your actual Develocity API key - Replace
your-openai-key-herewith your OpenAI API key (for AI Diagram Generator) - Update PostgreSQL credentials with your actual database connection details
- Replace
-
Python Servers: Ensure Python 3.8+ is installed and
logic-lm-mcp-serveris installed via pip. -
Package Names: Some packages may have different names on npm. If a package isn't found, check the GitHub repository for the correct package name or installation method.
Ensure you have Node.js 18+ installed:
node --version
npm --versionIf not installed, download from https://nodejs.org
Option A: Use Installation Script (Recommended)
Run the installation script for your platform:
# Windows (PowerShell)
.\scripts\install-mcp-servers.ps1
# Linux/macOS
./scripts/install-mcp-servers.shOption B: Manual Installation
Install all requested servers manually:
# Core servers (highest impact)
npm install -g @code-index/mcp-server
npm install -g @aakarsh-sasi/memory-bank-mcp
# Build and dependency management
npm install -g @gradle/develocity-mcp-server
npm install -g @antigravity/npm-plus-mcp
npm install -g @antigravity/spring-initializr-mcp
# Design and architecture
npm install -g @antoinebou12/uml-mcp
npm install -g @playbooks/ai-diagram-prototype-generator
npm install -g @squirrelogic/mcp-architect
# Database and tools
npm install -g @henkdz/postgresql-mcp-server
# Frontend
npm install --save-dev @storybook/addon-mcp
# Python-based servers (if not using npx)
pip install logic-lm-mcp-serverNote:
- Spring AI MCP Server requires building from source (see detailed instructions above)
- Spring Tools 5 Embedded MCP Server uses SSE endpoint (see configuration below)
- Storybook MCP Addon is installed as a dev dependency in your project
-
Open Cursor Settings
- Press
Ctrl+,(orCmd+,on Mac) - Navigate to Features → MCP (or search for "MCP")
- Press
-
Add MCP Servers
- Click "+ Add New MCP Server" or "Add MCP Server"
- Add each server using the configuration JSON above
- Toggle each server ON to enable it
-
Restart Cursor
- Important: After adding MCP servers, you must restart Cursor for them to take effect
- Close Cursor completely
- Reopen Cursor
- Open your project
Update application.yml:
management:
endpoints:
web:
exposure:
include: health,info,metrics,loggers,logfile
endpoint:
health:
show-details: always
loggers:
enabled: true
logfile:
enabled: true
external-file: ./logs/application.logQuick Verification:
# Check if npm packages are installed
npm list -g --depth=0 | grep -E "(code-index|memory-bank|develocity|npm-plus|spring-initializr|uml-mcp|docker|postgresql)"
# Check Python package
pip list | grep logic-lmNote: Some package names may differ on npm. If a package isn't found:
- Check the GitHub repository for the correct package name
- Some servers may need to be installed from source
- See individual installation instructions above
Restart Cursor and test by asking:
- "Index the codebase" (Code Index)
- "Remember that we use TDD approach" (Memory)
- "Generate a UML class diagram for a user service" (UML-MCP)
- "List all running Docker containers" (Docker)
- "What dependencies are outdated?" (NPM Plus)
- "Create a Spring Boot project with WebFlux" (Spring Initializr)
- "Show me the database schema" (PostgreSQL)
- "Generate a story for my Button component" (Storybook)
Since there isn't a ready-made Spring Boot Actuator MCP server, here's a simple Node.js implementation you can create:
#!/usr/bin/env node
const { Server } = require("@modelcontextprotocol/sdk/server/index.js");
const { StdioServerTransport } = require("@modelcontextprotocol/sdk/server/stdio.js");
const axios = require("axios");
const ACTUATOR_BASE_URL = process.env.ACTUATOR_BASE_URL || "http://localhost:8080/actuator";
const ACTUATOR_USERNAME = process.env.ACTUATOR_USERNAME;
const ACTUATOR_PASSWORD = process.env.ACTUATOR_PASSWORD;
const server = new Server(
{
name: "spring-actuator",
version: "1.0.0",
},
{
capabilities: {
tools: {},
},
}
);
async function makeRequest(endpoint) {
const url = `${ACTUATOR_BASE_URL}${endpoint}`;
const config = {};
if (ACTUATOR_USERNAME && ACTUATOR_PASSWORD) {
config.auth = {
username: ACTUATOR_USERNAME,
password: ACTUATOR_PASSWORD,
};
}
try {
const response = await axios.get(url, config);
return response.data;
} catch (error) {
throw new Error(`Actuator request failed: ${error.message}`);
}
}
server.setRequestHandler("tools/list", async () => ({
tools: [
{
name: "get_health",
description: "Get Spring Boot application health status",
inputSchema: {
type: "object",
properties: {},
},
},
{
name: "get_logs",
description: "Get recent application logs (requires logfile endpoint)",
inputSchema: {
type: "object",
properties: {
lines: {
type: "number",
description: "Number of lines to retrieve (default: 100)",
},
level: {
type: "string",
description: "Filter by log level (ERROR, WARN, INFO, DEBUG)",
enum: ["ERROR", "WARN", "INFO", "DEBUG"],
},
},
},
},
{
name: "get_metrics",
description: "Get application metrics",
inputSchema: {
type: "object",
properties: {
metric: {
type: "string",
description: "Specific metric name (optional)",
},
},
},
},
{
name: "get_info",
description: "Get application information",
inputSchema: {
type: "object",
properties: {},
},
},
],
}));
server.setRequestHandler("tools/call", async (request) => {
const { name, arguments: args } = request.params;
try {
switch (name) {
case "get_health":
return { content: [{ type: "text", text: JSON.stringify(await makeRequest("/health"), null, 2) }] };
case "get_logs":
const lines = args?.lines || 100;
const level = args?.level;
let logs = await makeRequest(`/logfile?lines=${lines}`);
if (level) {
logs = logs.split("\n").filter(line => line.includes(level)).join("\n");
}
return { content: [{ type: "text", text: logs }] };
case "get_metrics":
if (args?.metric) {
const metric = await makeRequest(`/metrics/${args.metric}`);
return { content: [{ type: "text", text: JSON.stringify(metric, null, 2) }] };
}
const metrics = await makeRequest("/metrics");
return { content: [{ type: "text", text: JSON.stringify(metrics, null, 2) }] };
case "get_info":
return { content: [{ type: "text", text: JSON.stringify(await makeRequest("/info"), null, 2) }] };
default:
throw new Error(`Unknown tool: ${name}`);
}
} catch (error) {
return {
content: [{ type: "text", text: `Error: ${error.message}` }],
isError: true,
};
}
});
async function main() {
const transport = new StdioServerTransport();
await server.connect(transport);
console.error("Spring Boot Actuator MCP server running on stdio");
}
main().catch(console.error);mkdir mcp-spring-actuator
cd mcp-spring-actuator
npm init -y
npm install @modelcontextprotocol/sdk axioschmod +x index.js{
"mcpServers": {
"spring-actuator": {
"command": "node",
"args": ["./mcp-spring-actuator/index.js"],
"env": {
"ACTUATOR_BASE_URL": "http://localhost:8080/actuator",
"ACTUATOR_USERNAME": "admin",
"ACTUATOR_PASSWORD": "admin"
}
}
}
}-
Code Index MCP 🔍
- Impact: 60-80% token savings on code queries
- Setup:
npm install -g @code-index/mcp-server
-
Memory MCP 🧠
- Impact: 20-40% token savings, maintains project knowledge
- Setup:
npm install -g @metorial/mcp-index
-
Spring Actuator MCP 📊
- Impact: 70-90% token savings on log queries
- Setup: Custom server (see above) or generic HTTP MCP
- Maven Tools MCP 🛠️:
npm install -g @maven-tools/mcp-server - Spring Initializr MCP 🚀:
npm install -g @antigravity/spring-initializr-mcp
Problem: npx can't find the MCP server package
Solution:
- Check if package name is correct
- Try installing globally:
npm install -g <package-name> - Use full path:
node /path/to/mcp-server/index.js
Problem: Cannot connect to Actuator endpoints
Solution:
- Ensure Spring Boot app is running
- Check
ACTUATOR_BASE_URLis correct - Verify endpoints are exposed in
application.yml - Check firewall/network settings
Problem: npm install -g fails with "package not found"
Solution:
- Some packages may have different names or may not be published to npm
- Check the GitHub repository for installation instructions
- Some servers (like Spring AI) need to be built from source
- Verify package names match exactly (case-sensitive)
Problem: Code Index doesn't find files
Solution:
- Verify
CODE_INDEX_PATHpoints to correct directory - Check file permissions
- Ensure codebase is not too large (may need chunking)
Problem: Cannot connect to Spring Tools 5 MCP server
Solution:
- Ensure Spring Tools 5 IDE is running
- Verify the MCP server is enabled in Spring Tools 5 settings
- Check that port 50627 is not blocked by firewall
- Try using stdio instead if SSE doesn't work
Problem: Storybook MCP addon doesn't appear
Solution:
- Ensure Storybook is running (
npm run storybook) - Verify the addon is configured in
.storybook/main.js - Check that the MCP endpoint is accessible at
http://localhost:6006/mcp - Restart Storybook after installing the addon
Problem: logic_lm_mcp_server module not found
Solution:
- Verify Python 3.8+ is installed
- Ensure pip installed to the correct Python:
python3 -m pip install logic-lm-mcp-server - Check that Clingo is installed:
pip install clingo - Verify the module path in MCP configuration
Problem: Memory Bank MCP not storing or retrieving data
Solution:
- Check that the
.memory-bankdirectory exists and is writable - Verify the path configuration in MCP settings
- Restart Cursor after configuration changes
- Actuator Endpoints: Secure in production with authentication
- Memory Storage: Don't store sensitive data (API keys, passwords)
- Network Access: Limit MCP server network access if possible
- Environment Variables: Keep secrets in
.env, not in MCP config
- Start with Code Index and Memory - Highest impact, easiest setup
- Add Develocity MCP - Build data analysis and insights
- Add Design Tools - UML-MCP and AI Diagram Generator for architecture planning
- Add Database Tools - PostgreSQL MCP for database management
- Customize as needed - Add more servers based on your workflow
- MCP Documentation: https://modelcontextprotocol.io
- Code Index MCP: https://github.com/ViperJuice/Code-Index-MCP
- Memory MCP: https://github.com/metorial/mcp-index
- Memory Bank MCP: https://github.com/aakarsh-sasi/memory-bank-mcp
- Spring Boot Actuator: https://docs.spring.io/spring-boot/docs/current/reference/html/actuator.html
- MCP Server Registry: https://mcp.so
Last Updated: 2025-01-27