Are you the author? Sign in to claim
MCP Tools that can help on Java development
MCP Java Dev Tools bridges agentic coding tools and live Java runtime behavior through a lightweight sidecar agent.
Static analysis only gets you so far. By attaching directly to a running JVM, this tool surfaces bytecode-level runtime signals that static analysis alone can't see — enabling probe-verified inspection, targeted regression checks, runtime-path validation, and deterministic debugging workflows.
The runtime agent is built with ByteBuddy and works alongside JDWP rather than replacing it. On top of the probe layer, the system adds framework-aware data synthesis and strict, fail-closed tool contracts — so agent orchestrators can make decisions grounded in actual runtime proof, not inference.
The current focus is HTTP entrypoints. Non-HTTP protocol support is on the horizon but not yet implemented — it will need concrete models and validation targets before the core contracts can be generalized.
For operator workflows and end-to-end execution flows, see docs/how-it-works/README.md.
| Requirement | Version |
|---|---|
| Node.js | v24.13.0 (tested) |
| npm | 11.6.2 (tested) |
| JDK | 17+ |
| Maven | any recent |
npm.cmd install
npm.cmd run build
mvn -f java-agent\pom.xml package
This produces two artifacts:
dist/server.jsjava-agent/core/core-probe/target/mcp-java-dev-tools-agent-0.1.0-all.jarInstaller flow is split into install and update scripts (Codex and Kiro skills).
./scripts/install.sh
This installs the default skill set:
mcp-java-dev-tools-line-probe-runmcp-java-dev-tools-regression-suitemcp-java-dev-tools-regression-plan-craftermcp-java-dev-tools-regression-resultmcp-java-dev-tools-issue-reportmcp-java-dev-tools-bug-drillmcp-java-dev-tools-bug-fixmcp-java-dev-tools-probe-registry-managerTo update/overwrite existing installed skills (and add missing new skills):
./scripts/update.sh
Both scripts:
npm run build:compilemvn -f java-agent/pom.xml packageKiro and Claude Code behavior during install/update:
mcp-java-dev-tools-* are detected and can be deleted interactivelySKILL.md + expected folder presence)Default MCP registry env input can be skipped:
./scripts/install.sh --client codex --no-configure-mcp-env
# Or: ./scripts/install.sh --client claude --no-configure-mcp-env
MCP env input captures:
MCP_JAVA_AGENT_JAR (required; absolute path to built Java agent jar)Use the helper launcher to run a Spring app with auto-inferred Java agent include scope and probe port:
./spring-integration/run-spring-app-with-mcp.sh
Behavior:
8080), optional JDWP port, and Java 21 compatibilitysrc/main/java9173 and increments if occupiedJAVA_TOOL_OPTIONS including -javaagentThe target JVM must run on Java 17 or newer. If you're on Java 21, see Java 21 compatibility mode before continuing.
Add the following as a JVM argument when launching your application, replacing {desktopName}:
-javaagent:C:\Users\{desktopName}\repository\mcp-java-dev-tools\java-agent\core\core-probe\target\mcp-java-dev-tools-agent-0.1.7.jar=host=0.0.0.0;port=9191;exclude=com.nimbly.mcpjavadevtools.agent.**,**.config.**,**Test
Tip: The
includefilter is optional. If omitted, the agent infers an include scope from startup command metadata (sun.java.command), usually the startup class package (for examplecom.acme.app.**). Setincludeexplicitly when inference is ambiguous or too broad.
includesupports comma-separated basepaths:
- package globs (for example
com.thirdparty.service.**)- exact class FQCNs (for example
com.example.ApiClass)- mixed module/class targeting in one value (for example
com.example.app.**,com.example.api.**,com.thirdparty.SomeClass)
To confirm the agent is instrumenting your classes, check the startup logs for lines like:
[mcp-probe]: com.yourpackagename.yourclassname
If you don't see your classes listed, check your include filter.
-javaagent:... argument from aboveFinding the JAR path: If you're unsure of the absolute path, right-click the agent JAR in the Project panel and choose Copy Path > Absolute Path.
On Windows, use backslashes in the path (
C:\Users\...). On macOS/Linux, use forward slashes (/home/...or/Users/...).
-javaagent:... argument from aboveFinding the JAR path: Navigate to the JAR in your file system, right-click it, and copy the full path. Paste it into the agent argument, replacing the placeholder path.
On Windows, Eclipse accepts both forward and backslashes in paths, but backslashes are safer. Wrap the path in quotes if it contains spaces:
-javaagent:"C:\path with spaces\agent.jar"=...
Controls how many method captures the agent retains per probe point.
| Method | Value |
|---|---|
| Agent arg | captureMethodBufferSize=<1..32> |
| JVM property | -Dmcp.probe.capture.method.buffer.size=<1..32> |
| Environment variable | MCP_PROBE_CAPTURE_METHOD_BUFFER_SIZE=<1..32> |
Default is 3. Increase this if you need deeper capture history for a single probe point.
Required if your target JVM runs on Java 21. Enables ByteBuddy's experimental support for newer JVM internals.
| Method | Value |
|---|---|
| Agent arg | allowJava21=true (aliases: java21Compat=true, byteBuddyExperimental=true) |
| JVM property | -Dmcp.probe.bytebuddy.experimental=true (legacy alias: -Dmcp.probe.allow.java21=true) |
| Environment variable | MCP_PROBE_BYTEBUDDY_EXPERIMENTAL=true (legacy alias: MCP_PROBE_ALLOW_JAVA21=true) |
Default is false.
| Variable | Purpose |
|---|---|
MCP_JAVA_AGENT_JAR | Absolute path to the built Java agent jar used for probe-wired runtime startup |
| Variable | Default | Notes |
|---|---|---|
MCP_JAVA_REQUEST_MAPPING_RESOLVER_JAR | — | |
MCP_JAVA_REQUEST_MAPPING_RESOLVER_CLASSPATH | — | |
MCP_JAVA_BIN | — | |
MCP_PROBE_LINE_SELECTION_MAX_SCAN_LINES | 120 | Range: 10–2000 |
MCP_PROBE_WAIT_MAX_RETRIES | 1 | Max: 10 |
MCP_PROBE_WAIT_UNREACHABLE_RETRY_ENABLED | false | |
MCP_PROBE_WAIT_UNREACHABLE_MAX_RETRIES | 3 | Max: 10 |
MCP_PROBE_INCLUDE_EXECUTION_PATHS | false | Set true to include executionPaths arrays in probe payloads |
| Setting | Consumed By | Affects |
|---|---|---|
.mcpjvm/probe-config.json | MCP server | Canonical multi-probe routing with workspaces/profiles/probes |
include / exclude in -javaagent:... (or mcp.probe.include / MCP_PROBE_INCLUDE) | Java agent | Which classes are instrumented at runtime |
MCP_PROBE_INCLUDE_EXECUTION_PATHS | MCP server | Whether executionPaths arrays are included in returned probe payloads |
These paths are fixed and cannot be overridden.
| Endpoint | Path |
|---|---|
| Status | /__probe/status |
| Reset | /__probe/reset |
| Capture | /__probe/capture |
| Skill | Purpose |
|---|---|
mcp-java-dev-tools-line-probe-run | Line-level probe execution |
mcp-java-dev-tools-regression-suite | Regression check orchestration |
mcp-java-dev-tools-regression-plan-crafter | Craft and refine deterministic persisted regression plan specs (metadata.json, contract.json, plan.md) |
mcp-java-dev-tools-regression-result | Artifact-derived result rendering with extensible display templates (default endpoint table) |
mcp-java-dev-tools-issue-report | Sanitized issue reporting from session, runtime, and probe evidence |
mcp-java-dev-tools-bug-drill | Bounded method-level diagnosis using Route Synthesis and live Probe evidence |
mcp-java-dev-tools-bug-fix | Proposal-only issue localization and Probe-evidenced Java fix planning |
Contribution guidance lives in CONTRIBUTING.md.
The guide distinguishes between:
Start there before opening a large pull request or changing public tool contracts.
| Tool | |
|---|---|
debug_check | |
artifact_management | |
probe | |
route_synthesis | |
execution_profile_export | |
execution_orchestration |
Probe config Artifact runtime behavior:
.mcpjvm/probe-config.json.artifact_management with artifactType=probe_config and action=reload remains available as deterministic manual refresh/fallback.Run Claude Code as an MCP server so any agent can delegate coding tasks to it
Browser automation using accessibility snapshots instead of screenshots
Google's universal MCP server supporting PostgreSQL, MySQL, MongoDB, Redis, and 10+ databases
Official GitHub integration for repos, issues, PRs, and CI/CD workflows