Load Tests Deep Dive
⚠️ Make sure to visit the Load Tests Quickstart to get started quickly.
Overview
Goal of this document: Load testing to verify PATH works and scales under load.
The load tests verify:
- Service responses under load (data + latency)
- System reliability and performance
- Success metrics for Shannon protocol
- Scalability characteristics
We use the Vegeta library for HTTP load testing:
- Can generate thousands of requests/sec
- Collects detailed metrics including latency percentiles (p50, p95, p99)
- Supports custom configurations and attack parameters
- Validates JSON-RPC responses and success rates
Load Test Modes
PATH load tests support two distinct modes of operation:
Mode | Purpose | How it Works | Use Cases |
---|---|---|---|
Local PATH | Performance testing against local PATH instances | 1. Requires completed Quick Start and Shannon Cheat Sheet setup 2. Tests against local PATH instance | - Local development testing - Feature validation - Development iteration |
Grove Portal | Performance testing against Grove Portal | 1. Sends requests to Grove Portal gateway URL 2. Requires Grove Portal credentials or pre-configured files | - Testing production gateway - Production performance validation - Benchmarking |
Local PATH Mode
For local PATH load testing, you need:
- Completed Setup: Follow the Quick Start and Shannon Cheat Sheet guides
- Local PATH Instance: Your local PATH instance should be running and configured
- Default Configuration: The system automatically targets your local PATH instance
Grove Portal Mode
You will need one of the following:
-
Grove Employee Pre-configured Files
- Download from 1Password links above
- Copy to
e2e/config/.grove.e2e_load_test.config.yaml
-
Custom Portal Access
gateway_url_override
:https://rpc.grove.city/v1
- Get credentials from the Grove Portal
- Use
make config_copy_e2e_load_test
to set up
Load Test Configuration
Configuration files used:
Configuration File | Local PATH | Grove Portal | Default Available? |
---|---|---|---|
./e2e/config/.grove.e2e_load_test.config.yaml | ❌ | ✅ | ❌ |
./e2e/config/.e2e_load_test.config.yaml | ✅ | ✅ | e2e/config/e2e_load_test.config.tmpl.yaml |
You can use the following command to copy example configs and follow the instructions in your CLI:
make config_copy_e2e_load_test
Schema and Validation
The configuration uses a formal YAML schema with validation:
Schema Location: ./e2e/config/e2e_load_test.config.schema.yaml
If you are using VSCode, we recommend using the YAML Language Support extension for in-editor validation of the .config.yaml
file.
Enable it by ensuring the following annotation is present at the top of your config file:
# yaml-language-server: $schema=https://raw.githubusercontent.com/buildwithgrove/path/refs/heads/main/e2e/config/e2e_load_test.config.schema.yaml
Supported Services in Load Tests
All currently supported Grove Portal services are supported in the load tests.
To see the list of supported services for the tests, see the test_cases
array in the Load Test Config file.
Test Metrics and Validation
The load tests collect and validate comprehensive metrics across multiple dimensions:
Category | Metrics Collected |
---|---|
HTTP Metrics | - Success rates (HTTP 200) - Status code distribution - HTTP error categorization |
Latency Metrics | - P50, P95, P99 latency percentiles - Average latency - Per-method latency analysis |
JSON-RPC Validation | - Response unmarshaling success - JSON-RPC error field validation - Result field validation - Protocol-specific validation |
Service-Level Metrics | - Per-service success aggregation - Cross-method performance comparison - Service reliability scoring - Error categorization and reporting |
Tests will fail if any configured thresholds are exceeded, ensuring consistent service quality and performance.
Reviewing PATH Logs
When running against local PATH instances, logs may be written to ./path_log_load_test_{timestamp}.txt
.
In order to enable this, set the log_to_file field:
yq eval '.e2e_load_test_config.load_test_config.log_to_file = true' -i ./e2e/config/.e2e_load_test.config.yaml
You should see the following log line at the bottom of the test summary:
===== 👀 LOGS 👀 =====
✍️ PATH container output logged to /tmp/path_log_load_test_1745527319.txt ✍️
===== 👀 LOGS 👀 =====