Skip to main content

Advanced MCP server for JMeter performance test analysis with 14 comprehensive tools

Project description

JMeter MCP Server - Advanced Edition

Package: jmeter-mcp-server v2.0.0 | Status: โœ… Published on PyPI | Date: January 27, 2026


๐Ÿš€ Quick Start

What is This?

An advanced MCP (Model Context Protocol) server with 14 comprehensive tools for analyzing, correlating, and enhancing JMeter performance test plans. Works seamlessly with Autogen, Claude, GPT-4, and any LLM via MCP protocol.

Installation & Usage

# Install from PyPI
pip install jmeter-mcp-server

# Run the server
jmeter-mcp

# Use with Autogen
from autogen_ext.models.openai import AzureOpenAIChatCompletionClient
from autogen_ext.tools.mcp import McpWorkbench, StdioServerParams
from autogen_agentchat.agents import AssistantAgent

server_params = StdioServerParams(
    command="python",
    args=["-m", "jmeter_mcp.cli"]
)

async with McpWorkbench(server_params) as workbench:
    agent = AssistantAgent(
        name="jmeter_analyst",
        model_client=model_client,
        workbench=workbench,
        system_message="You are a JMeter performance testing expert."
    )

๐Ÿ“ฆ Package Contents

Source Code

jmeter_mcp/
โ”œโ”€โ”€ __init__.py                           Package metadata
โ”œโ”€โ”€ cli.py                                MCP server entry point
โ””โ”€โ”€ jmeter_adva_mcp_o_14_Aug_25.py        Advanced server (2593 lines, 14 tools)

Configuration

pyproject.toml           Package config (PEP 517/518)
LICENSE                  MIT License
README.md                This documentation

๐Ÿ”ง Available Tools (14 Advanced Tools)

1. run_test

Run a JMeter test plan with specified users and settings.

Input:

  • jmx_path (string): Path to the JMX test plan file
  • users (integer): Number of concurrent users
  • ramp_time (integer, optional): Ramp-up time in seconds
  • duration (integer, optional): Test duration in seconds

Output: Test execution results and metrics

2. analyze_results

Analyze the results from a JTL (JMeter Test Log) file.

Input: jtl_path (string): Path to the JTL results file
Output: Performance metrics (response times, throughput, error rates)

3. analyze_any_log_file

Analyze any log file to extract insights and metrics.

Input: log_path (string): Path to any log file
Output: Extracted insights and analysis results

4. generate_analysis_report

Generate a comprehensive analysis report from a log file.

Input:

  • log_path (string): Path to the log file
  • output_path (string, optional): Path for the output report

Output: Detailed analysis report with charts and metrics

5. detect_log_format

Auto-detects log format with confidence score.

Input: log_path (string): Path to the log file
Output: Format type and confidence (jmeter_jtl, performance_csv, etc.)

6. analyze_easytravel_traces

Analyze EasyTravel CSV trace files for performance insights.

Input:

  • csv_path (string): Path to the EasyTravel CSV trace file
  • application_name (string, optional): Application name for filtering

Output: Extracted traces and performance metrics

7. correlate_jmeter_files

Run full JMeter correlation workflow to identify and add dynamic value extractors between XML logs and a JMX file.

Input:

  • jmx_path (string): Path to the JMX test plan
  • xml1_path (string): Path to the first XML execution log
  • xml2_path (string): Path to the second XML execution log
  • output_path (string, optional): Path for the updated JMX file

Output: Updated JMX file with dynamic value extractors added

8. parse_jmeter_xml_samples

Parse JMeter XML log file and extract sample data.

Input: xml_path (string): Path to the XML log file
Output: Parsed sample data with timestamps, response codes, and times

9. find_jmeter_dynamic_values

Find dynamic values between two JMeter XML execution logs.

Input:

  • xml1_path (string): Path to the first XML log
  • xml2_path (string): Path to the second XML log

Output: List of dynamic values that changed between executions

10. add_regex_extractor_to_jmx

Add a Regular Expression Extractor to a specific sampler in a JMX file.

Input:

  • jmx_path (string): Path to the JMX file
  • variable_name (string): Name of the variable to extract
  • regex (string): Regular expression pattern
  • sampler_name (string): Name of the sampler
  • output_path (string, optional): Path for the modified JMX file

Output: Updated JMX file with regex extractor added

11. add_dynatrace_headers

Add Dynatrace headers to all HTTP requests in a JMX file.

Input:

  • jmx_path (string): Path to the JMX file
  • application_name (string): Application name for the headers
  • transaction_controller_name (string): Transaction controller name
  • output_path (string, optional): Output path for the updated JMX file

Output: Updated JMX file with Dynatrace headers

12. auto_tag_dynatrace_headers

Automatically add Dynatrace headers with auto-detected transaction controllers.

Input:

  • jmx_path (string): Path to the JMX file
  • application_name (string): Application name
  • output_path (string, optional): Output path for the modified JMX file

Output: Updated JMX file with auto-tagged Dynatrace headers

13. batch_analyze_logs

Analyze multiple log files matching given patterns.

Input:

  • file_patterns (array): List of file patterns to match
  • output_dir (string, optional): Directory to save analysis results

Output: Analysis results for all matched files

14. correlate_complex_scopes

Handle complex correlation scenarios with multiple scopes and transaction controllers.

Input:

  • jmx_path (string): Path to the JMX file
  • correlation_rules (array): List of correlation rules
  • output_path (string, optional): Output path for the modified JMX file

Output: Updated JMX file with complex correlations applied

๐ŸŒŸ Why jmeter-mcp-server?

Powerful Analysis

  • Analyze JMeter test results and generate comprehensive reports
  • Detect performance issues and bottlenecks
  • Support for multiple log formats (JTL, CSV, and more)

Intelligent Correlation

  • Automatically find dynamic values between test executions
  • Add regex extractors to handle variable data
  • Support for complex correlation scenarios

Monitoring Integration

  • Add Dynatrace headers for APM integration
  • Auto-detect transaction controllers
  • Support for advanced monitoring setups

Seamless Integration

  • Works with any LLM via MCP protocol (Claude, GPT-4, etc.)
  • Native Autogen support
  • Easy deployment and scaling

๐Ÿš€ Installation

From PyPI (Recommended)

pip install jmeter-mcp-server

# Start the server
jmeter-mcp

From Source

git clone https://github.com/jeswanth/jmeter-mcp-server.git
cd jmeter-mcp-server
pip install -e .
jmeter-mcp

๐Ÿ’ก Usage Examples

Example 1: Analyze Test Results

import asyncio
from autogen_ext.tools.mcp import McpWorkbench, StdioServerParams
from autogen_agentchat.agents import AssistantAgent

async def analyze_test():
    server_params = StdioServerParams(
        command="python",
        args=["-m", "jmeter_mcp.cli"]
    )
    
    async with McpWorkbench(server_params) as workbench:
        agent = AssistantAgent(
            name="analyst",
            workbench=workbench,
        )
        
        result = await agent.run(
            task="Analyze the results from results.jtl and tell me the error rate"
        )
        print(result.messages[-1].content)

asyncio.run(analyze_test())

Example 2: Find Dynamic Values

# Use the find_jmeter_dynamic_values tool to compare two test runs
task = "Compare test_run_1.xml and test_run_2.xml to find dynamic values that changed"

Example 3: Add Correlation

# Use the correlate_jmeter_files tool to automatically add extractors
task = """
Use the correlate_jmeter_files tool to:
1. Compare Test1.xml and Test2.xml
2. Find dynamic values
3. Add regex extractors to my_test_plan.jmx
"""

๐Ÿ“‹ Requirements

  • Python: 3.9 or higher

  • Core Dependencies:

    • mcp >= 1.0.0
    • fastmcp >= 0.1.0
    • pandas >= 2.0.0
    • numpy >= 1.24.0
    • lxml >= 4.9.0
  • Optional Dependencies:

    • analysis: matplotlib, seaborn, scipy, scikit-learn
    • autogen: pyautogen, autogen-agentchat, autogen-ext, openai, tiktoken

๏ฟฝ Updates & Releases

Version 2.0.0 (Current)

  • โœ… 14 advanced tools for comprehensive JMeter analysis
  • โœ… Full MCP protocol support
  • โœ… Autogen integration
  • โœ… Multiple format support
  • โœ… Complex correlation handling

๐Ÿ“š Documentation


๐Ÿค Contributing

Contributions are welcome! Please:

  1. Fork the repository
  2. Create a feature branch
  3. Submit a pull request

๏ฟฝ License

MIT License - See LICENSE file for details


๐Ÿ‘ค Author

Jeswanth
Email: jeswanth@capgemini.com


๐Ÿ†˜ Support

  • Open an issue on GitHub
  • Check the documentation
  • Review tool examples

Last Updated: January 27, 2026
Package Version: 2.0.0

๐Ÿ” Constraints & Features

Constraint Status Details
Stdio-only MCP โœ… JSON-RPC 2.0 over stdin/stdout
No HTTP/FastAPI โœ… Pure stdio, no web framework
Stateless operation โœ… Parameter-driven, no session state
No file I/O โœ… All data via JSON parameters
Logs to stderr โœ… stream=sys.stderr configured
Works with pipx run โœ… Entry point registered & tested
Free publication โœ… PyPI hosts packages free

๐Ÿ“ Folder Structure

jmeter-mcp-package/
โ”œโ”€โ”€ jmeter_mcp/                      Python package
โ”‚   โ”œโ”€โ”€ __init__.py
โ”‚   โ””โ”€โ”€ cli.py
โ”œโ”€โ”€ dist/                            Build artifacts
โ”‚   โ”œโ”€โ”€ jmeter_mcp-1.0.0-py3-none-any.whl
โ”‚   โ””โ”€โ”€ jmeter_mcp-1.0.0.tar.gz
โ”œโ”€โ”€ pyproject.toml                   Modern package config
โ”œโ”€โ”€ LICENSE                          MIT License
โ”œโ”€โ”€ verify.py                        Verification script
โ””โ”€โ”€ README.md                        This complete guide

๐ŸŽฌ Publishing Workflow

1. Update pyproject.toml metadata (2 min)
   โ†“
2. Create PyPI account (5 min)
   โ†“
3. Generate & save API token (2 min)
   โ†“
4. Run: python -m twine upload dist/* (1 min)
   โ†“
5. Wait 5-10 minutes for PyPI indexing
   โ†“
6. Test: pipx install jmeter-mcp
   โ†“
โœ… PUBLISHED!

๐ŸŽ Use Cases

Performance Analysis

# Analyze JMeter test results
pipx run jmeter-mcp

With Claude/Autogen

# Analyze logs with AI assistance
agent.chat("Analyze this JMeter result and find issues")

CI/CD Integration

# In GitHub Actions or Jenkins
pipx run jmeter-mcp < test_results.csv

๐Ÿ“ž Quick Links

Link Purpose
https://pypi.org Python Package Index
https://pypi.org/account/register/ Create PyPI account
https://modelcontextprotocol.io MCP specification
https://microsoft.github.io/autogen/ Autogen documentation

โœจ Next Steps

  1. Review this guide
  2. Update pyproject.toml with your name/email
  3. Verify everything: python verify.py
  4. Create free PyPI account
  5. Publish: python -m twine upload dist/*
  6. Test: pipx install jmeter-mcp

๐Ÿ“œ License

MIT License - Free to use, modify, and distribute


Status: โœ… Production Ready | Created: January 27, 2026

Ready to publish? Update pyproject.toml and run: python -m twine upload dist/*

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

jmeter_mcp_server-2.0.1.tar.gz (32.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

jmeter_mcp_server-2.0.1-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file jmeter_mcp_server-2.0.1.tar.gz.

File metadata

  • Download URL: jmeter_mcp_server-2.0.1.tar.gz
  • Upload date:
  • Size: 32.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for jmeter_mcp_server-2.0.1.tar.gz
Algorithm Hash digest
SHA256 94a2a5b5c03bc62940adfa90b84cf8b5484b358aaa3c86c6afe31e5112fc4786
MD5 83219f9bf789aabe67f9caed62e95e7c
BLAKE2b-256 44f5b2665ad84b1228bd4211cdc96a40fc8300d03ae4f992f67b88a0b40025a6

See more details on using hashes here.

File details

Details for the file jmeter_mcp_server-2.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for jmeter_mcp_server-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 174bc80479653f294727855db8faaa04432937fb43d9c0c7dc555fa1381a65a7
MD5 329073054be56826314994a01cb9192e
BLAKE2b-256 ed5673d3185afea1178a1e719ea1f0ad84ed63230b1a45589b19690f375500ab

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page