Get the FREE Ultimate OpenClaw Setup Guide →

jolokia

Let LLMs manage your Java application via JMX/Jolokia 🌶️

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio jolokia-jolokia-mcp-server java -jar <path-to-the-runner-jar>/jolokia-mcp-server-0.5.0-runner.jar

How to use

The Jolokia MCP Server integrates Jolokia's JMX-HTTP bridge with the MCP (Model Context Protocol) so an LLM can manage a Java application via JMX. When run as a standalone MCP server, it connects to a remote Jolokia endpoint and exposes a set of tools that let you inspect and manipulate MBeans on the connected JVM. The provided tools let you list MBeans, discover available operations and attributes, and read or modify attributes or execute operations on MBeans. This makes it possible to query a Java application's management interface and perform controlled operations from an MCP-enabled workflow or chat-based assistant.

To use the server, register it with your MCP host using the provided configuration. Then run the Jolokia MCP Server using the standalone runner jar (as shown in the Install section). The server communicates with your Java application through Jolokia (the Jolokia agent must be attached to the target JVM). Once connected, you can invoke the 6 tools: listMBeans, listMBeanOperations, listMBeanAttributes, readMBeanAttribute, writeMBeanAttribute, and executeMBeanOperation. Each tool exposes clearly defined inputs and outputs to let an LLM construct sequences of management actions against the target JVM.

How to install

Prerequisites:

  • Java (JDK 8+)
  • Access to download the Jolokia MCP Server standalone runner jar or build it from source if preferred

Install options:

  1. Standalone runner (official jar)
  • Download the runner jar, e.g. jolokia-mcp-server-0.5.0-runner.jar
  • Place it in a known path on the MCP host
  1. Using MCP host configuration
  • Edit your MCP host settings to register the Jolokia server using the standalone method shown below

Register the Jolokia MCP Server (Standalone):

{
  "mcpServers": {
    "jolokia": {
      "command": "java",
      "args": [
        "-jar",
        "<path-to-the-runner-jar>/jolokia-mcp-server-0.5.0-runner.jar"
      ]
    }
  }
}
  1. Alternative (JBang) method
  • If you prefer JBang, you can run the server without downloading the jar:
{
  "mcpServers": {
    "jolokia": {
      "command": "jbang",
      "args": [
        "org.jolokia.mcp:jolokia-mcp-server:0.5.0:runner"
      ]
    }
  }
}
  1. JVM Agent installation (optional reference)
  • If you are using the JVM Agent distribution, attach the Jolokia MCP server JVM agent jar to your application or run via the provided runner as described in the README.

Notes:

  • Ensure the Jolokia agent is attached to the target JVM and accessible at the Jolokia endpoint (default http://localhost:8778/jolokia or the one you configure).
  • The standalone runner expects a Jolokia URL as the endpoint when creating the MCP server, typically via the positional parameter or configured at runtime.

Additional notes

Tips and common issues:

  • If you switch to HTTP transport, you can enable it with the --sse flag and adjust the Jolokia endpoint accordingly. The default HTTP transport port is 8080, and the SSE root path is /mcp by default.
  • Environment properties (quarkus.* and jolokia.*) are used to customize HTTP server behavior and the MCP transport. For example: quarkus.http.port sets the HTTP port for the SSE endpoint; jolokia.mcp.url can be used as an alias for the Jolokia endpoint if not using the positional parameter.
  • Ensure the MCP host can reach the Jolokia endpoint from the Java application’s network scope (firewalls, NAT, and container networking can affect reachability).
  • When debugging, check the MCP server logs for transport initialization messages and for any Jolokia connection issues (e.g., incorrect endpoint URL or unreachable agent).
  • The README references two distributions (Standalone and JVM Agent). Choose Standalone for a traditional MCP host integration, or JVM Agent if you want the MCP server to be a drop-in JVM agent within the target application.

Related MCP Servers

Sponsor this space

Reach thousands of developers