JMeter MCP Server
🚀 JMeter MCP 服务器
这是一个模型上下文协议 (MCP) 服务器,允许通过 MCP 兼容客户端执行 JMeter 测试。
[!重要] 📢 正在寻找 JMeter 中的 AI 助手?🚀 看看Feather Wand



📋 功能
📊 以非 GUI 模式执行 JMeter 测试
🖥️ 以 GUI 模式启动 JMeter
📝 捕获并返回执行输出
Related MCP server: MCP Server
🛠️ 安装
本地安装
安装
uv:确保 JMeter 已安装在您的系统上并可通过命令行访问。
⚠️重要提示:请确保 JMeter 可执行。你可以运行以下命令来执行此操作:
chmod +x /path/to/jmeter/bin/jmeter配置
.env文件,具体参考.env.example文件。
# JMeter Configuration
JMETER_HOME=/path/to/apache-jmeter-5.6.3
JMETER_BIN=${JMETER_HOME}/bin/jmeter
# Optional: JMeter Java options
JMETER_JAVA_OPTS="-Xms1g -Xmx2g"💻 MCP 使用
使用 MCP 兼容客户端(例如 Claude Desktop、Cursor、Windsurf)连接到服务器
向服务器发送提示:
Run JMeter test /path/to/test.jmxMCP 兼容客户端将使用可用的工具:
execute_jmeter_test:以 GUI 模式启动 JMeter,但不按照 JMeter 设计执行测试execute_jmeter_test_non_gui:以非 GUI 模式执行 JMeter 测试(默认模式可获得更好的性能)
🏗️ MCP 配置
将以下配置添加到您的 MCP 客户端配置中:
{
"mcpServers": {
"jmeter": {
"command": "/path/to/uv",
"args": [
"--directory",
"/path/to/jmeter-mcp-server",
"run",
"jmeter_server.py"
]
}
}
}✨ 用例
LLM 支持的结果分析:收集和分析测试结果。
调试:以非 GUI 模式执行测试进行调试。
🛑 错误处理
服务器将:
验证测试文件是否存在
检查文件是否具有 .jmx 扩展名
捕获并返回任何执行错误
Available Tools
6 toolsanalyze_jmeter_resultsC
Analyze JMeter test results and provide a summary of key metrics and insights.
Args: jtl_file: Path to the JTL file containing test results detailed: Whether to include detailed analysis (default: False)
Returns: str: Analysis results in a formatted string
Inputs: jtl_file (required), detailed. Returns: result
execute_jmeter_testB
Execute a JMeter test.
Args: test_file: Path to the JMeter test file (.jmx) gui_mode: Whether to run in GUI mode (default: False) properties: Dictionary of JMeter properties to pass with -J (default: None)
Inputs: test_file (required), gui_mode, properties. Returns: result
execute_jmeter_test_non_guiB
Execute a JMeter test in non-GUI mode - supports JMeter properties.
Args: test_file: Path to the JMeter test file (.jmx) properties: Dictionary of JMeter properties to pass with -J (default: None) generate_report: Whether to generate report dashboard after load test (default: False) report_output_dir: Output folder for report dashboard (default: None) log_file: Name of JTL file to log sample results to (default: None)
Inputs: test_file (required), generate_report, log_file, properties, +1 more. Returns: result
generate_visualizationC
Generate visualizations of JMeter test results.
Args: jtl_file: Path to the JTL file containing test results visualization_type: Type of visualization to generate (time_series, distribution, comparison, html_report) output_file: Path to save the visualization
Returns: str: Path to the generated visualization file
Inputs: jtl_file (required), output_file (required), visualization_type (required). Returns: result
get_performance_insightsC
Get insights and recommendations for improving performance based on JMeter test results.
Args: jtl_file: Path to the JTL file containing test results
Returns: str: Performance insights and recommendations in a formatted string
Inputs: jtl_file (required). Returns: result
identify_performance_bottlenecksB
Identify performance bottlenecks in JMeter test results.
Args: jtl_file: Path to the JTL file containing test results
Returns: str: Bottleneck analysis results in a formatted string
Inputs: jtl_file (required). Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
Most tools have distinct purposes, but there is some overlap between analyze_jmeter_results, get_performance_insights, and identify_performance_bottlenecks, as all three analyze JTL files and provide insights. However, their descriptions differentiate them enough to avoid major confusion.
All tool names follow a consistent snake_case pattern with clear verb_noun structure, such as analyze_jmeter_results and execute_jmeter_test. The naming is uniform and predictable throughout the set.
With 6 tools, the count is well-scoped for a JMeter server, covering key operations like test execution, result analysis, and visualization. Each tool serves a clear purpose without redundancy.
The toolset covers core JMeter workflows including test execution, result analysis, and visualization, but lacks tools for test creation or modification. This minor gap does not severely hinder typical agent tasks.
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Apache JMeter community documentation, conversion tools, linters, and calculators for AI agents.
MCP server for building and testing AI agents with multi-model experimentation and insights.
A Model Context Protocol server for Wix AI tools
Related MCP Servers
- AlicenseCqualityDmaintenanceA Model Context Protocol (MCP) server implementation that allows AI assistants to run k6 load tests through natural language commands, supporting custom test durations and virtual users.226MIT
- AlicenseNot gradedqualityDmaintenanceModel Context Protocol server that enables API test automation across various AI hosts (Claude, OpenAI, custom) using Postman Collections.MIT
- FlicenseCqualityDmaintenanceA Model Context Protocol server that enables executing and interacting with JMeter tests through MCP-compatible clients like Claude Desktop, Cursor, and Windsurf.2-
- FlicenseCqualityDmaintenanceA Model Context Protocol server that enables execution of JMeter performance tests through AI assistants and MCP-compatible clients like Claude, Cursor, and Windsurf.2-