Skip to content

Latest commit

Β 

History

185 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Spring-Forge

Version IntelliJ Plugin License Java Kotlin

Architecture-aware Spring Boot development toolkit for IntelliJ IDEA

Features β€’ Installation β€’ Quick Start β€’ Documentation β€’ Contributing


πŸš€ Overview

SpringForge is a comprehensive IntelliJ IDEA plugin that streamlines Spring Boot development with AI-powered code generation, architecture analysis, and CI/CD automation. It combines ML-based pattern detection with AWS Bedrock's Claude AI to help developers build better Spring Boot applications faster.

Key Capabilities

  • πŸ—οΈ Architecture-Aware Code Generation - Generate Spring Boot projects with proper architectural patterns
  • πŸ€– AI-Powered CI/CD - Automatically generate Dockerfiles, GitHub Actions, and Kubernetes manifests
  • πŸ” Quality Analysis - ML-based detection of architecture violations and anti-patterns
  • πŸ› Runtime Debugging - Advanced runtime analysis and performance monitoring
  • 🌐 GitHub Integration - Analyze remote repositories via MCP protocol

✨ Features

1. Code Generation Module

Generate production-ready Spring Boot projects with intelligent scaffolding:

  • Create New Projects - Full project setup with architecture template selection
  • Existing Project Analysis - ML-powered architecture pattern detection
  • Smart Scaffolding - Generate controllers, services, repositories with proper layers
  • LLM Prompt Generation - Parse input.yml and build context for AI code generation

Supported Architecture Patterns:

  • Layered Architecture
  • Hexagonal (Ports & Adapters)
  • Clean Architecture
  • Event-Driven Architecture
  • Microservices

2. CI/CD Assistant

AI-powered DevOps artifact generation using AWS Bedrock Claude Sonnet 4.5:

  • Dockerfile Generation - Optimized multi-stage builds with architecture detection
  • GitHub Actions Workflows - Complete CI/CD pipelines with testing, building, and deployment
  • Docker Compose - Multi-service configurations with detected dependencies
  • Kubernetes Manifests - Production-ready deployments, services, and ingress

Source Options:

  • πŸ“ Local IntelliJ project analysis
  • πŸ”— Remote GitHub repository analysis (via GitHub MCP Server)

3. Quality Assurance

ML-powered architecture violation detection:

  • Anti-Pattern Detection - Identify common Spring Boot anti-patterns
  • Architecture Compliance - Validate adherence to architectural principles
  • Severity Levels - Critical, High, Medium classifications
  • Detailed Reports - File-level violations with recommendations

4. Runtime Debugger

Advanced runtime analysis tools:

  • Performance monitoring
  • Memory leak detection
  • Request tracing
  • Metrics collection

5. Unified Tool Window

Modern sidebar interface with tabbed navigation:

  • Always accessible from IntelliJ sidebar
  • Real-time progress tracking
  • Integrated output console
  • Similar UX to Maven, Gradle, and Copilot panels

πŸ“‹ Requirements

Minimum Requirements

  • IntelliJ IDEA: 2024.3 or later (Ultimate Edition recommended)
  • Java: JDK 21 or later
  • Operating System: Windows, macOS, or Linux

Required for Full Functionality

  • AWS Account with Bedrock access (for CI/CD generation)
    • Claude Sonnet 4 model enabled in us-east-1
    • IAM credentials with bedrock:InvokeModel permission

Optional (for GitHub Integration)

  • Docker Desktop (for GitHub MCP Server)
  • GitHub Personal Access Token (for remote repository analysis)

πŸ”§ Installation

Option 1: Install from JetBrains Marketplace (Coming Soon)

  1. Open IntelliJ IDEA
  2. Go to Settings β†’ Plugins β†’ Marketplace
  3. Search for "SpringForge Tools"
  4. Click Install and restart IDE

Option 2: Build from Source

# Clone the repository
git clone https://github.com/springforgeecosystem-prog/Spring-Forge.git
cd Spring-Forge

# Build the plugin
./gradlew buildPlugin

# The plugin will be in build/distributions/

Install the plugin:

  1. Go to Settings β†’ Plugins β†’ βš™οΈ β†’ Install Plugin from Disk
  2. Select build/distributions/Spring-Forge-1.0-SNAPSHOT.zip
  3. Restart IntelliJ IDEA

βš™οΈ Configuration

1. AWS Bedrock Setup (Required for CI/CD)

Enable Claude Sonnet 4 in AWS Bedrock:

# Verify Bedrock access
aws bedrock list-foundation-models --region us-east-1 \
  --query 'modelSummaries[?contains(modelId, `claude-sonnet-4`)]'

Create .env file in your project root:

cp .env.example .env

Edit .env with your credentials:

# AWS Bedrock Configuration
AWS_REGION=us-east-1
AWS_ACCESS_KEY_ID=your_access_key_here
AWS_SECRET_ACCESS_KEY=your_secret_access_key_here

# Claude Configuration (optional - uses defaults)
CLAUDE_MODEL_ID=us.anthropic.claude-sonnet-4-20250514-v1:0
CLAUDE_MAX_TOKENS=4000

IAM Policy Required:

{
  "Version": "2012-10-17",
  "Statement": [{
    "Effect": "Allow",
    "Action": "bedrock:InvokeModel",
    "Resource": "arn:aws:bedrock:us-east-1::foundation-model/anthropic.claude-sonnet-4*"
  }]
}

2. GitHub MCP Setup (Optional)

For analyzing remote GitHub repositories:

Step 1: Install Docker Desktop

Step 2: Create GitHub Personal Access Token

  1. Go to GitHub Settings β†’ Tokens
  2. Create token with repo, public_repo, read:org permissions
  3. Copy the token

Step 3: Configure Environment

Add to .env:

GITHUB_PERSONAL_ACCESS_TOKEN=ghp_your_token_here
GITHUB_HOST=https://github.com
GITHUB_READ_ONLY=true

Verify Setup:

# Test GitHub MCP connectivity
docker ps  # Ensure Docker is running

πŸ“– Detailed Setup Guide: docs/github-mcp-setup.md


πŸš€ Quick Start

Using the Tool Window (Recommended)

  1. Open SpringForge Sidebar

    • Look for "SpringForge" tab on the right side of IntelliJ
    • Or go to View β†’ Tool Windows β†’ SpringForge
  2. Choose a Module

    • Code Gen - Generate new projects or analyze existing ones
    • CI/CD - Generate DevOps artifacts
    • Quality - Analyze code quality
    • Runtime - Launch runtime debugger

Example: Generate CI/CD Files

Method 1: Using Tool Window (New!)

  1. Click SpringForge in right sidebar
  2. Switch to CI/CD tab
  3. Select source:
    • βœ… Local Project (current IntelliJ project)
    • βœ… GitHub Repository (enter URL like https://github.com/spring-projects/spring-petclinic)
  4. Check files to generate:
    • βœ… Dockerfile
    • βœ… GitHub Actions Workflow
    • βœ… Docker Compose
  5. Click Generate CI/CD Files
  6. Monitor progress in output console

Method 2: Using Menu Actions

  1. Open a Spring Boot project in IntelliJ
  2. Go to Tools β†’ SpringForge β†’ Generate CI/CD Pipeline
  3. Select source and options
  4. Click OK

Output Files:

your-project/
β”œβ”€β”€ Dockerfile                    # Multi-stage optimized build
β”œβ”€β”€ docker-compose.yml            # Multi-service orchestration
β”œβ”€β”€ .github/
β”‚   └── workflows/
β”‚       └── build.yml             # Complete CI/CD pipeline
└── k8s/
    └── deployment.yml            # Kubernetes manifests

Example: Analyze Code Quality

  1. Open SpringForge tool window
  2. Switch to Quality tab
  3. Click Analyze Code Quality
  4. View results in the panel:
    • Architecture pattern detected
    • Violations by severity
    • Affected files and recommendations

Example: Create New Project

  1. Open SpringForge tool window
  2. Switch to Code Gen tab
  3. Click Create New Spring Boot Project
  4. Select:
    • Architecture pattern (Layered, Hexagonal, Clean, etc.)
    • Dependencies (Web, JPA, Security, etc.)
    • Project metadata (group, artifact, package)
  5. Click Generate

πŸ“š Documentation

User Guides

Technical Documentation

Feature Documentation


πŸ—οΈ Architecture

Project Structure

Spring-Forge/
β”œβ”€β”€ src/main/
β”‚   β”œβ”€β”€ java/org/springforge/
β”‚   β”‚   β”œβ”€β”€ cicdassistant/          # CI/CD generation module
β”‚   β”‚   β”‚   β”œβ”€β”€ actions/            # IntelliJ actions
β”‚   β”‚   β”‚   β”œβ”€β”€ bedrock/            # AWS Bedrock client
β”‚   β”‚   β”‚   β”œβ”€β”€ github/             # GitHub MCP integration
β”‚   β”‚   β”‚   β”œβ”€β”€ mcp/                # MCP protocol models
β”‚   β”‚   β”‚   β”œβ”€β”€ parsers/            # Code analyzers
β”‚   β”‚   β”‚   └── services/           # Business logic
β”‚   β”‚   β”œβ”€β”€ codegeneration/         # Code generation module
β”‚   β”‚   β”‚   β”œβ”€β”€ actions/            # Project creation actions
β”‚   β”‚   β”‚   └── ui/                 # UI dialogs
β”‚   β”‚   β”œβ”€β”€ qualityassurance/       # Quality analysis module
β”‚   β”‚   β”‚   β”œβ”€β”€ actions/            # Analysis actions
β”‚   β”‚   β”‚   β”œβ”€β”€ toolwindow/         # Legacy tool window
β”‚   β”‚   β”‚   └── ui/                 # UI components
β”‚   β”‚   β”œβ”€β”€ runtimeanalysis/        # Runtime debugger module
β”‚   β”‚   β”‚   └── actions/            # Debugger actions
β”‚   β”‚   β”œβ”€β”€ toolwindow/             # Unified sidebar panel (NEW)
β”‚   β”‚   β”‚   β”œβ”€β”€ panels/             # Tab panels
β”‚   β”‚   β”‚   β”œβ”€β”€ SpringForgeToolWindowFactory.kt
β”‚   β”‚   β”‚   β”œβ”€β”€ SpringForgeToolWindowPanel.kt
β”‚   β”‚   β”‚   └── SpringForgeToolWindowService.kt
β”‚   β”‚   └── icons/                  # Icon provider
β”‚   └── resources/
β”‚       β”œβ”€β”€ META-INF/
β”‚       β”‚   └── plugin.xml          # Plugin configuration
β”‚       └── icons/                  # Plugin icons
β”œβ”€β”€ docs/                           # Documentation
β”œβ”€β”€ build.gradle.kts                # Gradle build configuration
└── .env.example                    # Environment template

Key Technologies

Component Technology Purpose
Plugin Framework IntelliJ Platform SDK IDE integration
Language Kotlin 1.9.23 Plugin development
AI Integration AWS Bedrock + Claude Sonnet 4.5 Code generation
Code Analysis JavaParser 3.25.7 AST analysis
MCP Protocol Custom JSON-RPC 2.0 GitHub integration
HTTP Client OkHttp 4.11.0 Network communication
YAML Parsing SnakeYAML 2.1 Configuration parsing
Async Operations Kotlin Coroutines Background tasks

🀝 Contributing

We welcome contributions! Please follow these guidelines:

Development Setup

  1. Clone the repository

    git clone https://github.com/springforgeecosystem-prog/Spring-Forge.git
    cd Spring-Forge
  2. Open in IntelliJ IDEA

    • File β†’ Open β†’ Select Spring-Forge directory
    • Wait for Gradle sync to complete
  3. Configure environment

    cp .env.example .env
    # Add your AWS credentials
  4. Run the plugin

    • Click Run β†’ Run Plugin
    • New IntelliJ window opens with plugin installed

Development Workflow

  1. Create a feature branch

    git checkout -b feat/your-feature-name
  2. Make changes

    • Follow Kotlin coding conventions
    • Add tests for new features
    • Update documentation
  3. Test thoroughly

    ./gradlew test
    ./gradlew runPluginVerifier
  4. Commit with conventional commits

    git commit -m "feat: add new feature description"

    Types: feat, fix, docs, style, refactor, test, chore

  5. Push and create PR

    git push origin feat/your-feature-name

Code Standards

  • Kotlin Style: Follow Kotlin Coding Conventions
  • Documentation: Add KDoc comments for public APIs
  • Testing: Write unit tests for business logic
  • Error Handling: Use proper exception handling and user-friendly messages

Areas for Contribution

  • πŸ› Bug Fixes - Check Issues
  • ✨ New Features - Architecture patterns, generators, analyzers
  • πŸ“– Documentation - Improve guides, add examples
  • πŸ§ͺ Testing - Increase test coverage
  • 🎨 UI/UX - Enhance user interface

πŸ§ͺ Testing

Run Tests

# Run all tests
./gradlew test

# Run plugin verifier (compatibility check)
./gradlew runPluginVerifier

# Run with coverage
./gradlew test jacocoTestReport

Manual Testing

  1. Test CI/CD Generation

    # Use test project
    cd test-projects/spring-petclinic
    # Generate via plugin
  2. Test GitHub Integration

    # Run MCP verification
    ./test-github-mcp.ps1
  3. Test Quality Analysis

    • Open a Spring Boot project
    • Run quality analysis from tool window
    • Verify results are accurate

πŸ“¦ Building for Distribution

Build Plugin ZIP

./gradlew buildPlugin

Output: build/distributions/Spring-Forge-1.0-SNAPSHOT.zip

Build for Marketplace

# Set version in build.gradle.kts
version = "1.0.0"

# Build
./gradlew buildPlugin

# Verify
./gradlew runPluginVerifier

πŸ› Troubleshooting

Common Issues

❌ AWS Credentials Not Working

  • Verify credentials in .env file
  • Check IAM permissions for Bedrock
  • Test with: aws bedrock list-foundation-models --region us-east-1
  • See: AWS Credentials Troubleshooting

❌ GitHub MCP Connection Failed

  • Ensure Docker Desktop is running
  • Verify GITHUB_PERSONAL_ACCESS_TOKEN in .env
  • Check token permissions: repo, public_repo
  • See: GitHub MCP Debugging

❌ Plugin Not Showing in Sidebar

  • Restart IntelliJ IDEA
  • Check: View β†’ Tool Windows β†’ SpringForge
  • Verify plugin is enabled in Settings β†’ Plugins

❌ Icon Not Displaying

  • Rebuild plugin: ./gradlew clean buildPlugin
  • Reinstall plugin
  • See: Custom Icon Guide

Getting Help

  1. Check Documentation
  2. Search Issues
  3. Create new issue with:
    • Plugin version
    • IntelliJ version
    • Error logs from Help β†’ Show Log in Explorer

πŸ“ Changelog

Version 1.0.0 (2026-01-03)

✨ Features

  • Unified Tool Window - New sidebar interface with 4 modules
  • GitHub MCP Integration - Analyze remote repositories
  • Enhanced CI/CD Generation - AWS Bedrock Claude Sonnet 4.5 integration
  • Architecture Detection - ML-powered pattern recognition
  • Background Task Progress - Real-time progress tracking

πŸ› Bug Fixes

  • Fixed GitHub branch auto-detection
  • Resolved Docker line-ending issues
  • Improved error handling for MCP protocol

πŸ“– Documentation

  • Added comprehensive setup guides
  • Created troubleshooting documentation
  • Added API documentation

See full changelog for complete history.


πŸ™ Acknowledgments

  • AWS Bedrock - Claude AI integration
  • Anthropic - Claude Sonnet 4.5 model
  • JetBrains - IntelliJ Platform SDK
  • Spring Framework - Architecture patterns and best practices
  • JavaParser - Java code analysis
  • Model Context Protocol (MCP) - GitHub integration protocol

πŸ“ž Contact & Support


πŸ—ΊοΈ Roadmap

v1.1.0 (Planned)

  • JetBrains Marketplace release
  • Additional architecture patterns (CQRS, Event Sourcing)
  • Terraform/CloudFormation generation
  • GitLab CI integration
  • Enhanced test generation

v1.2.0 (Future)

  • Multi-module project support
  • Custom architecture templates
  • Integration with SonarQube
  • Performance benchmarking tools
  • Database migration generators

v2.0.0 (Vision)

  • VS Code extension
  • CLI tool for CI/CD integration
  • Cloud-based analysis service
  • Team collaboration features

Made with ❀️ by the SpringForge Team

⭐ Star us on GitHub β€” it helps!

⬆ Back to Top

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages