Spring Flow Visualizer
Enterprise-grade static analysis, dependency visualization, and AI-powered insights for Spring Boot projects — directly inside VS Code.
Features
Dependency Graph
Interactive React Flow graph of your entire Spring Boot architecture:
- Controllers, Services, Repositories, Entities, Configurations, DTOs
- Infrastructure nodes: Redis, Kafka, RabbitMQ, WebClient, FeignClient
- Edge types: injects, calls, persists, caches, publishes, extends, implements
- Filter by category, search by class name, minimap, layout direction
API Explorer
- All REST endpoints grouped by controller
- HTTP method badges (GET / POST / PUT / DELETE / PATCH)
- Parameters, security annotations, validation, deprecation flags
- Click to navigate directly to source
Quality Dashboard 🛡
Automated architecture quality analysis with letter grade (A–F) and score (0–100):
| Check |
Description |
| Layer Violations |
Controllers calling Repositories directly, Services depending on Controllers |
| Circular Dependencies |
Full cycle chain with all affected components |
| Unused Beans |
Spring-managed beans never injected anywhere |
| Unused Repositories |
Repositories not consumed by any Service |
| Missing @Transactional |
Write-path methods without transaction boundary |
| Missing @Valid |
Request bodies without input validation |
| Unreachable Endpoints |
Controller handlers with no HTTP path |
AI Insights ✨
Powered by Claude (Anthropic). Select any node or endpoint and choose an insight type:
- Explain API — business purpose, callers, constraints, security notes
- Business Flow — capability, role, downstream interactions
- Architecture — pattern detection, strengths, top risks
- Optimizations — caching, async, transaction scope improvements
- Bottlenecks — N+1 queries, blocking ops, thread-safety issues
Plugin System
Extensible analyzer plugins run after each scan:
- Spring Batch — detects jobs, steps, processors, missing transaction config
- GraphQL — detects @QueryMapping / @MutationMapping / @SubscriptionMapping, missing @Transactional on mutations
- Custom plugins via the
SpringFlowPlugin interface
Requirements
- VS Code 1.85+
- A workspace containing
pom.xml, build.gradle, or build.gradle.kts
- Java source files with Spring Boot annotations
- For AI features: an Anthropic API key (get one here)
Setup
AI Insights (Optional)
- Get an API key from console.anthropic.com
- Open VS Code Settings (
Ctrl+,)
- Search for
springFlow.aiApiKey
- Paste your key
The key is stored in your VS Code user settings and never leaves your machine (calls go directly from the extension to api.anthropic.com).
Usage
- Open a Spring Boot project in VS Code
- The extension auto-activates and scans on startup (configurable)
- Click the Spring Flow icon in the activity bar to open the sidebar
- Click Open Dashboard (preview icon) for the full-screen view
- For AI insights: open the AI ✨ tab, select a node in the graph, choose a feature, and click Generate Insight
Commands
| Command |
Description |
Spring Flow: Scan Project |
Full re-scan of the workspace |
Spring Flow: Refresh |
Incremental refresh |
Spring Flow: Open Dashboard |
Open the full-screen dashboard |
Spring Flow: Analyze Current File |
Analyze the currently open Java file |
Spring Flow: Clear AI Insight Cache |
Reset cached AI responses |
Extension Settings
| Setting |
Default |
Description |
springFlow.scanOnOpen |
true |
Auto-scan when workspace opens |
springFlow.incrementalIndexing |
true |
Re-index changed files on save |
springFlow.excludePatterns |
["**/target/**", ...] |
Glob patterns to exclude |
springFlow.maxFilesPerBatch |
50 |
Files per parse batch |
springFlow.logLevel |
"info" |
Output channel log level |
springFlow.aiApiKey |
"" |
Anthropic API key for AI features |
springFlow.enableArchitectureAnalysis |
true |
Run quality analysis after scans |
springFlow.enablePlugins |
true |
Enable built-in analyzer plugins |
Plugin API
Implement the SpringFlowPlugin interface to add custom analyzers:
import { SpringFlowPlugin, PluginContext, PluginResult } from 'spring-flow-visualizer';
export class MyPlugin implements SpringFlowPlugin {
readonly id = 'my-plugin';
readonly name = 'My Custom Analyzer';
readonly description = 'Detects XYZ patterns';
readonly version = '1.0.0';
analyze(ctx: PluginContext): PluginResult {
const issues = [];
// Inspect ctx.components, ctx.apiIndex, ctx.rootPath
return { issues, metrics: { myMetric: 42 } };
}
}
- Batch parsing with configurable batch size
- LRU component cache — unchanged files are never re-parsed
- File modification cache — mtime-based incremental updates
- Analysis runs asynchronously after scan, never blocking the UI
- AI responses are cached per component per session
Privacy
- All analysis is 100% local and static — no code is sent anywhere
- AI features make direct HTTPS calls from your machine to
api.anthropic.com only when you click Generate Insight
- Your API key is stored only in VS Code settings on your local machine
Contributing
- Fork the repository
npm install && cd webview && npm install
- Press F5 in VS Code to launch the Extension Development Host
- Submit a PR against the
develop branch
License
MIT — see LICENSE
| |