Skip to main content

HAR-based load testing CLI for jac-scale applications

Project description

jac-loadtest

HAR-based load testing CLI for jac-scale applications. Capture real browser traffic via Chrome DevTools, export it as a .har file, and replay it under load — no scripting required.

The tool registers itself as a jac subcommand, so after installation you run jac loadtest alongside jac start, jac deploy, and the rest of the jac ecosystem.

Quick Start

# Minimal: 1 VU, 30s
jac loadtest recording.har --url http://localhost:8000

# 50 VUs with 10s ramp-up
jac loadtest recording.har --url http://localhost:8000 --vus 50 --ramp-up 10s --duration 60s

# Authenticated test with per-VU credentials
jac loadtest recording.har --url http://localhost:8000 --vus 20 --credentials-file creds.csv

# CI-friendly with thresholds
jac loadtest recording.har --url http://localhost:8000 \
  --vus 10 --duration 30s --fail-on-p95 500 --fail-on-error-rate 1

Developer Setup

# 1. Create and activate a conda env (Python 3.12 required)
conda create -n load python=3.12
conda activate load

# 2. Install the package in editable mode (runtime deps only)
pip install -e .

# 3. Also install test dependencies (when running tests)
pip install -e ".[test]"

# 4. Verify the command is registered
jac loadtest --help

Project Layout

jac_loadtest/
├── plugin.py      — registers `jac loadtest` via jaclang entry-points
├── cli.py         — argument wiring; JacMetaImporter bootstrap
├── config.py      — LoadTestConfig dataclass (three-layer resolution)
├── core/          — HAR parser, load engine, metrics (no jac-scale knowledge)
├── bridge/        — jac-scale-aware adapters (auth, topology)
└── output/        — console, JSON, HTML reporters

The hard boundary between core/ and bridge/ is what keeps the eventual migration to jac-scale[loadtest] a file move rather than a rewrite.

HAR Compatibility

Tested with HAR 1.1 and 1.2 (the format exported by Chrome DevTools, Firefox, Postman, and Insomnia). Files from other versions are parsed with a warning — open an issue if something breaks.

Documentation

  • Architecture — module map, data flow, design decisions
  • Roadmap — delivery phases and exit criteria
  • Verification — phase-by-phase manual and automated verification checklists

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

jac_loadtest-0.1.0.tar.gz (12.9 kB view details)

Uploaded Source

Built Distribution

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

jac_loadtest-0.1.0-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file jac_loadtest-0.1.0.tar.gz.

File metadata

  • Download URL: jac_loadtest-0.1.0.tar.gz
  • Upload date:
  • Size: 12.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for jac_loadtest-0.1.0.tar.gz
Algorithm Hash digest
SHA256 625698ed46feda2fb0bb154e2149af33f1efe1d028267b09b8f93ba8c5d31c34
MD5 93544acfb0c89d06d51d6fe5ae9ef045
BLAKE2b-256 c667f10ec0d64c4eb4bd5ea1345520790b021c25bc6dd663b60ad07c84646654

See more details on using hashes here.

File details

Details for the file jac_loadtest-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: jac_loadtest-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for jac_loadtest-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1661c92de6e99a7d196a6549cbde1d653e00e02123825638adb8304dac7ffde5
MD5 92fa1ec913ca05aa90c213bca184d5ad
BLAKE2b-256 2887f010f2beb82a968e58548a390f1b2df002c92452030974e8cf8ab04c2e6e

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