overload-cli 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- overload_cli-0.1.0/.gitignore +20 -0
- overload_cli-0.1.0/AGENTS.md +148 -0
- overload_cli-0.1.0/CHANGELOG.md +70 -0
- overload_cli-0.1.0/LICENSE +21 -0
- overload_cli-0.1.0/PKG-INFO +267 -0
- overload_cli-0.1.0/README.md +228 -0
- overload_cli-0.1.0/docs/architecture.html +129 -0
- overload_cli-0.1.0/docs/assertions.html +156 -0
- overload_cli-0.1.0/docs/authentication.html +158 -0
- overload_cli-0.1.0/docs/browser-ui.html +138 -0
- overload_cli-0.1.0/docs/changelog.html +114 -0
- overload_cli-0.1.0/docs/ci-cd.html +254 -0
- overload_cli-0.1.0/docs/cli-reference.html +230 -0
- overload_cli-0.1.0/docs/collections.html +182 -0
- overload_cli-0.1.0/docs/configuration.html +137 -0
- overload_cli-0.1.0/docs/contributing.html +133 -0
- overload_cli-0.1.0/docs/getting-started.html +178 -0
- overload_cli-0.1.0/docs/index.html +277 -0
- overload_cli-0.1.0/docs/reports.html +134 -0
- overload_cli-0.1.0/docs/styles.css +868 -0
- overload_cli-0.1.0/docs/test-patterns.html +317 -0
- overload_cli-0.1.0/pyproject.toml +74 -0
- overload_cli-0.1.0/src/overload/__init__.py +3 -0
- overload_cli-0.1.0/src/overload/__main__.py +5 -0
- overload_cli-0.1.0/src/overload/cli.py +393 -0
- overload_cli-0.1.0/src/overload/collection/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/collection/environment.py +23 -0
- overload_cli-0.1.0/src/overload/collection/models.py +88 -0
- overload_cli-0.1.0/src/overload/collection/parser.py +220 -0
- overload_cli-0.1.0/src/overload/collection/variables.py +84 -0
- overload_cli-0.1.0/src/overload/config_file.py +73 -0
- overload_cli-0.1.0/src/overload/engine/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/engine/assertions.py +151 -0
- overload_cli-0.1.0/src/overload/engine/auth.py +87 -0
- overload_cli-0.1.0/src/overload/engine/events.py +50 -0
- overload_cli-0.1.0/src/overload/engine/http_client.py +274 -0
- overload_cli-0.1.0/src/overload/engine/load_patterns.py +730 -0
- overload_cli-0.1.0/src/overload/engine/models.py +254 -0
- overload_cli-0.1.0/src/overload/engine/rate_limiter.py +124 -0
- overload_cli-0.1.0/src/overload/engine/runner.py +86 -0
- overload_cli-0.1.0/src/overload/report/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/report/exporters.py +77 -0
- overload_cli-0.1.0/src/overload/report/generator.py +71 -0
- overload_cli-0.1.0/src/overload/report/templates/report.html +369 -0
- overload_cli-0.1.0/src/overload/utils/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/utils/naming.py +26 -0
- overload_cli-0.1.0/src/overload/web/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/web/app.py +38 -0
- overload_cli-0.1.0/src/overload/web/routes/__init__.py +1 -0
- overload_cli-0.1.0/src/overload/web/routes/api.py +461 -0
- overload_cli-0.1.0/src/overload/web/routes/ws.py +77 -0
- overload_cli-0.1.0/src/overload/web/static/css/app.css +242 -0
- overload_cli-0.1.0/src/overload/web/static/js/app.js +241 -0
- overload_cli-0.1.0/src/overload/web/static/js/charts.js +385 -0
- overload_cli-0.1.0/src/overload/web/static/js/collection.js +344 -0
- overload_cli-0.1.0/src/overload/web/static/js/runner.js +625 -0
- overload_cli-0.1.0/src/overload/web/templates/index.html +23 -0
- overload_cli-0.1.0/tests/test_api.py +162 -0
- overload_cli-0.1.0/tests/test_assertions.py +251 -0
- overload_cli-0.1.0/tests/test_auth.py +242 -0
- overload_cli-0.1.0/tests/test_collection_parser.py +199 -0
- overload_cli-0.1.0/tests/test_config_file.py +99 -0
- overload_cli-0.1.0/tests/test_http_client.py +86 -0
- overload_cli-0.1.0/tests/test_models.py +162 -0
- overload_cli-0.1.0/tests/test_report.py +105 -0
- overload_cli-0.1.0/tests/test_variables.py +129 -0
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
__pycache__/
|
|
2
|
+
*.pyc
|
|
3
|
+
*.pyo
|
|
4
|
+
.venv/
|
|
5
|
+
*.egg-info/
|
|
6
|
+
dist/
|
|
7
|
+
build/
|
|
8
|
+
.eggs/
|
|
9
|
+
overload_report_*.html
|
|
10
|
+
overload_results_*.json
|
|
11
|
+
overload_results_*.csv
|
|
12
|
+
.pytest_cache/
|
|
13
|
+
.mypy_cache/
|
|
14
|
+
.ruff_cache/
|
|
15
|
+
tmp_workdir/
|
|
16
|
+
reports/
|
|
17
|
+
overload.config.yaml
|
|
18
|
+
ttd_collection.json
|
|
19
|
+
.DS_Store
|
|
20
|
+
tmp_workdir/
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
# Overload — Project Guide
|
|
2
|
+
|
|
3
|
+
## What is this?
|
|
4
|
+
|
|
5
|
+
Overload is a free, open-source load testing tool that reads Postman collections and provides a browser-based UI. Published as `overload` on PyPI, command is `overload`.
|
|
6
|
+
|
|
7
|
+
## Quick Start
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
pip install -e ".[dev]" # Install in dev mode
|
|
11
|
+
overload # Opens browser UI on port 3000
|
|
12
|
+
overload run --collection path/to/collection.json --pattern burst # CLI mode
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Project Structure
|
|
16
|
+
|
|
17
|
+
```
|
|
18
|
+
src/overload/ # Main package (src layout)
|
|
19
|
+
collection/ # Postman collection parsing (parser, models, variables, environment)
|
|
20
|
+
engine/ # Test execution (http_client, load_patterns, runner, rate_limiter, events)
|
|
21
|
+
report/ # HTML report generation + CSV/JSON export
|
|
22
|
+
templates/ # Jinja2 templates, CSS, JS for reports
|
|
23
|
+
web/ # FastAPI browser UI
|
|
24
|
+
routes/ # API endpoints + WebSocket
|
|
25
|
+
static/css/ # UI stylesheets
|
|
26
|
+
static/js/ # Vanilla JS frontend (app, collection, runner, charts)
|
|
27
|
+
templates/ # index.html SPA shell
|
|
28
|
+
utils/ # Naming, timestamps
|
|
29
|
+
cli.py # CLI entry point
|
|
30
|
+
tests/ # Unit tests (pytest)
|
|
31
|
+
fixtures/ # Sample Postman collections for tests
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Tech Stack
|
|
35
|
+
|
|
36
|
+
- **Python 3.10+**, asyncio for concurrency
|
|
37
|
+
- **FastAPI + Uvicorn** — web server, WebSocket
|
|
38
|
+
- **httpx** — async HTTP client
|
|
39
|
+
- **Jinja2** — report templates
|
|
40
|
+
- **Vanilla JS + Chart.js** — frontend (no build step)
|
|
41
|
+
- **pytest** — testing
|
|
42
|
+
|
|
43
|
+
## Development Principles
|
|
44
|
+
|
|
45
|
+
- **Build it right the first time.** Write complete, production-quality code on the first pass. Do not leave TODOs, placeholders, or partial implementations to revisit later.
|
|
46
|
+
- **First principles thinking.** Understand the problem from the ground up before writing code. Don't copy patterns blindly — reason about why a particular approach is correct for this specific case.
|
|
47
|
+
- **Honest feedback.** If the user's approach is wrong or suboptimal, say so directly with reasoning. Don't silently go along with a bad idea.
|
|
48
|
+
- **Major changes require planning.** Any significant architectural change or new feature should be discussed and planned before implementation.
|
|
49
|
+
- **PEP 8 compliance.** Follow PEP 8 style guidelines strictly.
|
|
50
|
+
- **Lazy imports only when necessary.** Use module-level imports by default. Only use lazy imports when there's a concrete performance reason (e.g., heavy optional dependency in a rarely-used code path).
|
|
51
|
+
|
|
52
|
+
## Conventions
|
|
53
|
+
|
|
54
|
+
- **Type hints** on all function signatures
|
|
55
|
+
- **Dataclasses** for data models (not Pydantic for internal models; Pydantic only for FastAPI request/response schemas)
|
|
56
|
+
- **async/await** for all HTTP and I/O operations
|
|
57
|
+
- **No comments** unless the "why" is non-obvious
|
|
58
|
+
- Import order: stdlib, then third-party, then local (PEP 8)
|
|
59
|
+
- Use `from __future__ import annotations` in all files
|
|
60
|
+
|
|
61
|
+
## Git
|
|
62
|
+
|
|
63
|
+
- Never use Co-Authored-By in commit messages
|
|
64
|
+
- Use the repo owner's git credentials (already configured)
|
|
65
|
+
- Write clear, concise commit messages describing what changed and why
|
|
66
|
+
- Commit after every change
|
|
67
|
+
|
|
68
|
+
## Async & Concurrency Discipline
|
|
69
|
+
|
|
70
|
+
- All I/O-bound operations (HTTP requests, file reads during test runs, WebSocket) must use `async/await`. Never block the event loop with synchronous I/O.
|
|
71
|
+
- Use `asyncio.Semaphore` to control concurrency — never create unbounded numbers of tasks.
|
|
72
|
+
- Use `asyncio.Event` for cancellation signals — patterns must check the cancel event and stop gracefully.
|
|
73
|
+
- Never mix `threading` with `asyncio` unless there is no async alternative. If threads are necessary, use `asyncio.to_thread()` to bridge.
|
|
74
|
+
- All shared state accessed from multiple coroutines must be protected or designed to be safe (e.g., append-only lists, asyncio.Queue).
|
|
75
|
+
- Connection pools (httpx.AsyncClient) must be properly opened and closed using async context managers.
|
|
76
|
+
|
|
77
|
+
## Logging
|
|
78
|
+
|
|
79
|
+
- Use Python's `logging` module with `logger = logging.getLogger(__name__)` in every module.
|
|
80
|
+
- Log levels: `DEBUG` for detailed execution flow (request/response details, timing), `INFO` for high-level progress, `WARNING` for recoverable issues, `ERROR` for failures.
|
|
81
|
+
- When the user enables debug mode (`--debug` flag or `OVERLOAD_DEBUG=1`), set root logger to `DEBUG`.
|
|
82
|
+
- Default log level is `WARNING` for clean output.
|
|
83
|
+
- Never use `print()` for diagnostic output — always use the logger. `print()` is only for CLI user-facing progress output.
|
|
84
|
+
|
|
85
|
+
## Key Patterns
|
|
86
|
+
|
|
87
|
+
- **Load patterns** implement `LoadPattern` protocol with `async execute()` method
|
|
88
|
+
- **EventBus** decouples engine from transport (WebSocket, CLI print)
|
|
89
|
+
- **Collection parser** flattens nested Postman items, handles auth inheritance
|
|
90
|
+
- **Variable substitution** uses `{{var}}` regex with scoped resolution
|
|
91
|
+
|
|
92
|
+
## Commands
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
# Development
|
|
96
|
+
pip install -e ".[dev]" # Install with dev deps
|
|
97
|
+
python -m overload # Run via module
|
|
98
|
+
pytest tests/ # Run tests
|
|
99
|
+
pytest tests/ -x # Stop on first failure
|
|
100
|
+
|
|
101
|
+
# Package
|
|
102
|
+
python -m build # Build package
|
|
103
|
+
pip install dist/*.whl # Install built package
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
## Test Types
|
|
107
|
+
|
|
108
|
+
Load, Stress, Spike, Soak, Ramp, Burst, Breakpoint, Custom (step-based), Rate Limit, Sequential Runner.
|
|
109
|
+
|
|
110
|
+
## Dependencies
|
|
111
|
+
|
|
112
|
+
Runtime: fastapi, uvicorn, httpx, jinja2, python-multipart
|
|
113
|
+
Dev: pytest, pytest-asyncio
|
|
114
|
+
|
|
115
|
+
## Contributing
|
|
116
|
+
|
|
117
|
+
### Setup
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
git clone https://github.com/dprakash2101/overload
|
|
121
|
+
cd overload
|
|
122
|
+
python -m venv .venv && source .venv/bin/activate
|
|
123
|
+
pip install -e ".[dev]"
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Before submitting a PR
|
|
127
|
+
|
|
128
|
+
1. **Run the full test suite** — all tests must pass:
|
|
129
|
+
```bash
|
|
130
|
+
pytest tests/
|
|
131
|
+
```
|
|
132
|
+
2. **Add tests** for any new behaviour. The test suite covers every module; new code should not lower coverage.
|
|
133
|
+
3. **Follow the conventions** in this file — type hints, dataclasses, async/await, PEP 8, no unnecessary comments.
|
|
134
|
+
4. **Keep PRs focused.** One feature or fix per PR. If you are refactoring and adding a feature, split them.
|
|
135
|
+
|
|
136
|
+
### Areas open for contribution
|
|
137
|
+
|
|
138
|
+
- **New load patterns** — implement the `LoadPattern` protocol in [src/overload/engine/load_patterns.py](src/overload/engine/load_patterns.py)
|
|
139
|
+
- **Additional auth types** — extend `_apply_auth` in [src/overload/engine/http_client.py](src/overload/engine/http_client.py)
|
|
140
|
+
- **Report improvements** — HTML/CSS/JS lives in [src/overload/report/templates/](src/overload/report/templates/)
|
|
141
|
+
- **Browser UI features** — vanilla JS in [src/overload/web/static/js/](src/overload/web/static/js/)
|
|
142
|
+
- **Collection format support** — parser in [src/overload/collection/parser.py](src/overload/collection/parser.py)
|
|
143
|
+
|
|
144
|
+
### Submitting
|
|
145
|
+
|
|
146
|
+
- Fork the repo, create a branch off `main`, open a PR against `main`.
|
|
147
|
+
- Write a clear PR description: what changed, why, and how to test it.
|
|
148
|
+
- Do not open PRs for cosmetic-only changes (whitespace, renaming for style preference).
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## [0.1.0] — 2026-05-30
|
|
11
|
+
|
|
12
|
+
First public release.
|
|
13
|
+
|
|
14
|
+
### Added
|
|
15
|
+
|
|
16
|
+
**Core engine**
|
|
17
|
+
- Async HTTP engine built on `httpx` with connection pooling and configurable concurrency
|
|
18
|
+
- 10 load test patterns: Burst, Load, Stress, Spike, Soak, Ramp, Breakpoint, Custom (stage-based), Rate Limit, Sequential
|
|
19
|
+
- Postman Collection v2.1 parser — nested folders, auth inheritance, variable substitution, all body types (raw, form-data, urlencoded, GraphQL)
|
|
20
|
+
|
|
21
|
+
**Authentication**
|
|
22
|
+
- Bearer token auth
|
|
23
|
+
- HTTP Basic auth
|
|
24
|
+
- API key auth — header and query string placement
|
|
25
|
+
- OAuth2 client-credentials flow — pre-run token acquisition with in-process caching and `expires_in` respect
|
|
26
|
+
|
|
27
|
+
**Variable system**
|
|
28
|
+
- Three-scope variable resolution: runtime (`--var`) > environment file > collection variables
|
|
29
|
+
- Dynamic variables: `{{$guid}}`, `{{$timestamp}}`, `{{$randomInt}}`, `{{$randomBoolean}}`, `{{$randomEmail}}`
|
|
30
|
+
- Recursive resolution (a variable whose value references another variable)
|
|
31
|
+
|
|
32
|
+
**CI/CD assertions**
|
|
33
|
+
- `--assert "p95_latency_ms<500"` inline threshold expressions (repeatable)
|
|
34
|
+
- Exit code 1 on assertion failure — the primitive every CI system reads
|
|
35
|
+
- JUnit XML output via `--junit report.xml` — native test results in GitHub Actions, GitLab, Jenkins
|
|
36
|
+
- Colored terminal verdict table with per-assertion ✓/✗ rows
|
|
37
|
+
- YAML config file (`overload.config.yaml`) for storing test configuration and thresholds in source control
|
|
38
|
+
- `--config` flag to load the YAML config; CLI flags override file values
|
|
39
|
+
|
|
40
|
+
**Browser UI**
|
|
41
|
+
- FastAPI + Vanilla JS SPA — no build step, no Node.js required
|
|
42
|
+
- Auto-detects Postman collections and environment files in the working directory
|
|
43
|
+
- Live progress dashboard with Chart.js charts (RPS, latency, error rate)
|
|
44
|
+
- Assertions editor with metric/operator/value rows
|
|
45
|
+
- Save Config / Load Config — writes/reads `overload.config.yaml`
|
|
46
|
+
- PASS/FAIL verdict banner with per-assertion breakdown
|
|
47
|
+
- Past runs table with verdict badge
|
|
48
|
+
- HTML report viewer
|
|
49
|
+
|
|
50
|
+
**Reports**
|
|
51
|
+
- HTML report with embedded Chart.js charts and verdict section
|
|
52
|
+
- JSON export
|
|
53
|
+
- CSV export (one row per request)
|
|
54
|
+
- Reports written to `reports/` subdirectory
|
|
55
|
+
|
|
56
|
+
**CLI**
|
|
57
|
+
- `overload` — starts browser UI on port 3000
|
|
58
|
+
- `overload run` — headless CLI mode with full flag surface
|
|
59
|
+
- `overload sequential` — sequential runner for functional flows
|
|
60
|
+
- `--open-report` — opens HTML report in browser after run
|
|
61
|
+
|
|
62
|
+
**Supported metrics for assertions**
|
|
63
|
+
`p50_latency_ms`, `p95_latency_ms`, `p99_latency_ms`, `max_latency_ms`, `mean_latency_ms`,
|
|
64
|
+
`error_rate_pct`, `success_rate_pct`, `avg_rps`, `total_requests`, `rate_limited_count`
|
|
65
|
+
|
|
66
|
+
**Test suite**
|
|
67
|
+
- 124 unit tests across all layers (assertions, auth, collection parser, variables, HTTP client, models, report, API)
|
|
68
|
+
- GitHub Actions CI matrix: Python 3.10 · 3.11 · 3.12 · 3.13
|
|
69
|
+
|
|
70
|
+
[0.1.0]: https://github.com/dprakash2101/overload/releases/tag/v0.1.0
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Devi Prakash
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: overload-cli
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Free load testing tool that reads Postman collections — browser UI + CLI
|
|
5
|
+
Project-URL: Homepage, https://github.com/dprakash2101/overload
|
|
6
|
+
Project-URL: Repository, https://github.com/dprakash2101/overload
|
|
7
|
+
Project-URL: Issues, https://github.com/dprakash2101/overload/issues
|
|
8
|
+
Project-URL: Documentation, https://dprakash2101.github.io/overload/
|
|
9
|
+
Project-URL: Changelog, https://github.com/dprakash2101/overload/blob/main/CHANGELOG.md
|
|
10
|
+
Author: Devi Prakash
|
|
11
|
+
License-Expression: MIT
|
|
12
|
+
License-File: LICENSE
|
|
13
|
+
Keywords: api-testing,assertions,ci-cd,load-testing,performance,postman,stress-test
|
|
14
|
+
Classifier: Development Status :: 4 - Beta
|
|
15
|
+
Classifier: Environment :: Console
|
|
16
|
+
Classifier: Environment :: Web Environment
|
|
17
|
+
Classifier: Intended Audience :: Developers
|
|
18
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
19
|
+
Classifier: Programming Language :: Python :: 3
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
23
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
24
|
+
Classifier: Topic :: Software Development :: Testing
|
|
25
|
+
Classifier: Topic :: System :: Networking
|
|
26
|
+
Requires-Python: >=3.10
|
|
27
|
+
Requires-Dist: fastapi>=0.100.0
|
|
28
|
+
Requires-Dist: httpx>=0.24.0
|
|
29
|
+
Requires-Dist: jinja2>=3.1.0
|
|
30
|
+
Requires-Dist: python-multipart>=0.0.6
|
|
31
|
+
Requires-Dist: pyyaml>=6.0
|
|
32
|
+
Requires-Dist: uvicorn[standard]>=0.20.0
|
|
33
|
+
Provides-Extra: dev
|
|
34
|
+
Requires-Dist: build; extra == 'dev'
|
|
35
|
+
Requires-Dist: pytest-asyncio>=0.21; extra == 'dev'
|
|
36
|
+
Requires-Dist: pytest>=7.0; extra == 'dev'
|
|
37
|
+
Requires-Dist: twine; extra == 'dev'
|
|
38
|
+
Description-Content-Type: text/markdown
|
|
39
|
+
|
|
40
|
+
# Overload
|
|
41
|
+
|
|
42
|
+
Free, open-source load testing tool that reads Postman collections. Run tests from a browser dashboard or the terminal CLI.
|
|
43
|
+
|
|
44
|
+
**📚 [Read the Full Documentation](https://dprakash2101.github.io/overload/)**
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
## Install
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
pip install overload-cli
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Or in dev mode from source:
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
git clone https://github.com/dprakash2101/overload
|
|
58
|
+
cd overload
|
|
59
|
+
pip install -e ".[dev]"
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
---
|
|
63
|
+
|
|
64
|
+
## Two Ways to Run
|
|
65
|
+
|
|
66
|
+
### Option 1 — Browser UI (results on screen)
|
|
67
|
+
|
|
68
|
+
Run `overload` with no arguments. It starts a local server and opens a dashboard in your browser where you configure the test, watch live progress, and view charts and reports — **no terminal reading required**.
|
|
69
|
+
|
|
70
|
+
```bash
|
|
71
|
+
overload
|
|
72
|
+
# Opens http://localhost:3000 automatically
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
**Step-by-step in the browser:**
|
|
76
|
+
|
|
77
|
+
1. The app auto-detects any Postman collection JSON files in your working directory and lists them under **"Detected Files"**. Click **Load** next to the one you want.
|
|
78
|
+
2. Optionally load a Postman environment file the same way.
|
|
79
|
+
3. Pick the **Test Type** from the dropdown (Burst, Load, Stress, Spike, etc.).
|
|
80
|
+
4. Adjust the config fields that appear (concurrency, RPS, duration, etc.).
|
|
81
|
+
5. Click **Start Test**. The dashboard shows live progress: phase, request count, RPS, and a real-time latency chart.
|
|
82
|
+
6. When the test finishes, click **View Report** to open the full HTML report in a new tab — latency charts, timeline scatter, per-second breakdown, and the raw request log.
|
|
83
|
+
7. Click **Stop** at any time to cancel immediately with partial results saved.
|
|
84
|
+
|
|
85
|
+
**Options:**
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
overload ui --port 8080 # Use a different port
|
|
89
|
+
overload ui --no-browser # Start server without auto-opening browser
|
|
90
|
+
overload ui --host 0.0.0.0 # Bind to all interfaces (LAN access)
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
### Option 2 — CLI (results in terminal)
|
|
96
|
+
|
|
97
|
+
Run tests headlessly and see a progress bar + summary printed to the terminal. An HTML report is saved to disk.
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
overload run --collection path/to/collection.json --pattern burst
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
**Output looks like:**
|
|
104
|
+
|
|
105
|
+
```
|
|
106
|
+
OVERLOAD — BURST TEST
|
|
107
|
+
Collection: my_api.json
|
|
108
|
+
Requests: 5
|
|
109
|
+
Run ID: burst_20260529_abc123
|
|
110
|
+
|
|
111
|
+
[####################] 100% (200 requests) — complete
|
|
112
|
+
|
|
113
|
+
Results:
|
|
114
|
+
Total: 200 OK: 198 Errors: 2
|
|
115
|
+
Latency — min: 45ms p95: 312ms max: 891ms
|
|
116
|
+
Duration: 4.2s Avg RPS: 47.6
|
|
117
|
+
|
|
118
|
+
Report: /path/to/overload_report_20260529_abc123.html
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
**All CLI flags for `overload run`:**
|
|
122
|
+
|
|
123
|
+
| Flag | Default | Description |
|
|
124
|
+
|------|---------|-------------|
|
|
125
|
+
| `--collection` | *(required)* | Path to Postman collection JSON |
|
|
126
|
+
| `--environment` | — | Path to Postman environment JSON |
|
|
127
|
+
| `--pattern` | `burst` | Test type: `load`, `stress`, `spike`, `soak`, `ramp`, `burst`, `breakpoint`, `custom`, `ratelimit` |
|
|
128
|
+
| `--requests` | `200` | Total requests (burst / rate limit tests) |
|
|
129
|
+
| `--concurrency` | `20` | Max simultaneous connections |
|
|
130
|
+
| `--rps` | `50` | Target requests per second |
|
|
131
|
+
| `--duration` | `300` | Test duration in seconds |
|
|
132
|
+
| `--timeout` | `30` | Per-request timeout in seconds |
|
|
133
|
+
| `--stages` | — | Custom stages JSON: `'[{"duration":60,"rps":100}]'` |
|
|
134
|
+
| `--var KEY=VALUE` | — | Override a collection variable (repeatable) |
|
|
135
|
+
| `--save-responses` | off | Save response bodies in the report |
|
|
136
|
+
| `--no-verify-ssl` | off | Skip SSL certificate verification |
|
|
137
|
+
| `--output` | `reports` | Directory to write the HTML report |
|
|
138
|
+
| `--format` | `html` | Report format: `html`, `json`, `csv` |
|
|
139
|
+
| `--assert EXPR` | — | Assertion threshold (repeatable), e.g. `p95_latency_ms<500` |
|
|
140
|
+
| `--junit PATH` | — | Write JUnit XML report for CI systems |
|
|
141
|
+
| `--config PATH` | — | Load config from `overload.config.yaml` |
|
|
142
|
+
| `--open-report` | off | Open HTML report in browser after run |
|
|
143
|
+
|
|
144
|
+
**Sequential runner (run requests in order):**
|
|
145
|
+
|
|
146
|
+
```bash
|
|
147
|
+
overload sequential --collection my_api.json --iterations 5 --delay 500
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
| Flag | Default | Description |
|
|
151
|
+
|------|---------|-------------|
|
|
152
|
+
| `--collection` | *(required)* | Path to Postman collection JSON |
|
|
153
|
+
| `--environment` | — | Path to Postman environment JSON |
|
|
154
|
+
| `--iterations` | `1` | How many times to run the full collection |
|
|
155
|
+
| `--delay` | `0` | Milliseconds to wait between requests |
|
|
156
|
+
| `--timeout` | `30` | Per-request timeout in seconds |
|
|
157
|
+
| `--output` | `.` | Directory to write the HTML report |
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
## Test Types
|
|
162
|
+
|
|
163
|
+
| Type | What it does |
|
|
164
|
+
|------|-------------|
|
|
165
|
+
| **Burst** | Fires all N requests at once as fast as possible |
|
|
166
|
+
| **Load** | Sustained traffic — ramp up → hold at target RPS → ramp down |
|
|
167
|
+
| **Stress** | Steps up RPS until errors exceed the failure threshold |
|
|
168
|
+
| **Spike** | Baseline RPS → sudden spike → recovery, to test elasticity |
|
|
169
|
+
| **Soak** | Steady low RPS over a long duration (find memory leaks / drift) |
|
|
170
|
+
| **Ramp** | Linearly increases from start RPS to end RPS |
|
|
171
|
+
| **Breakpoint** | Binary search to find the exact RPS where latency or errors degrade |
|
|
172
|
+
| **Custom** | Define your own stages: `[{"duration": 60, "rps": 100}, ...]` |
|
|
173
|
+
| **Rate Limit** | Verifies that the API enforces its rate limit correctly |
|
|
174
|
+
| **Sequential** | Runs each request in collection order, N iterations |
|
|
175
|
+
|
|
176
|
+
---
|
|
177
|
+
|
|
178
|
+
## CI/CD Integration
|
|
179
|
+
|
|
180
|
+
Overload can gate your CI pipeline. Add assertions and the process exits `1` on failure — the universal CI signal.
|
|
181
|
+
|
|
182
|
+
**Inline assertions:**
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
overload run --collection api.json --pattern load --rps 100 --duration 60 \
|
|
186
|
+
--assert "p95_latency_ms<500" \
|
|
187
|
+
--assert "error_rate_pct<1" \
|
|
188
|
+
--junit results.xml
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
**Using a config file:**
|
|
192
|
+
|
|
193
|
+
Save your test config with assertions to `overload.config.yaml` (the browser UI can do this via **Save Config**):
|
|
194
|
+
|
|
195
|
+
```yaml
|
|
196
|
+
test_type: load
|
|
197
|
+
config:
|
|
198
|
+
target_rps: 100
|
|
199
|
+
hold_duration_seconds: 60
|
|
200
|
+
concurrency: 20
|
|
201
|
+
thresholds:
|
|
202
|
+
- metric: p95_latency_ms
|
|
203
|
+
operator: "<"
|
|
204
|
+
value: 500
|
|
205
|
+
- metric: error_rate_pct
|
|
206
|
+
operator: "<"
|
|
207
|
+
value: 1
|
|
208
|
+
```
|
|
209
|
+
|
|
210
|
+
Then in CI:
|
|
211
|
+
|
|
212
|
+
```bash
|
|
213
|
+
overload run --collection api.json --config overload.config.yaml --junit results.xml
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
**GitHub Actions example:**
|
|
217
|
+
|
|
218
|
+
```yaml
|
|
219
|
+
- name: Run load test
|
|
220
|
+
run: |
|
|
221
|
+
pip install overload-cli
|
|
222
|
+
overload run --collection tests/api.json \
|
|
223
|
+
--config overload.config.yaml \
|
|
224
|
+
--junit results.xml
|
|
225
|
+
|
|
226
|
+
- name: Publish test results
|
|
227
|
+
uses: dorny/test-reporter@v1
|
|
228
|
+
if: always()
|
|
229
|
+
with:
|
|
230
|
+
name: Load Test
|
|
231
|
+
path: results.xml
|
|
232
|
+
reporter: java-junit
|
|
233
|
+
```
|
|
234
|
+
|
|
235
|
+
**Available assertion metrics:** `p50_latency_ms`, `p95_latency_ms`, `p99_latency_ms`, `max_latency_ms`, `mean_latency_ms`, `error_rate_pct`, `success_rate_pct`, `avg_rps`, `total_requests`, `rate_limited_count`
|
|
236
|
+
|
|
237
|
+
**Operators:** `<`, `<=`, `>`, `>=`, `==`
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
## Quick Reference
|
|
242
|
+
|
|
243
|
+
```
|
|
244
|
+
# See results in browser (recommended)
|
|
245
|
+
overload
|
|
246
|
+
|
|
247
|
+
# See results in terminal
|
|
248
|
+
overload run --collection my_api.json --pattern burst --requests 100
|
|
249
|
+
|
|
250
|
+
# Debug mode (verbose logging)
|
|
251
|
+
overload --debug
|
|
252
|
+
# or
|
|
253
|
+
OVERLOAD_DEBUG=1 overload
|
|
254
|
+
```
|
|
255
|
+
|
|
256
|
+
---
|
|
257
|
+
|
|
258
|
+
## Working Directory
|
|
259
|
+
|
|
260
|
+
When you launch `overload` from a directory that contains Postman JSON files, the UI auto-detects and lists them. Start from your project folder:
|
|
261
|
+
|
|
262
|
+
```bash
|
|
263
|
+
cd path/to/my-api-tests/
|
|
264
|
+
overload
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
The HTML report is also saved to the working directory after each test.
|