result-api-scaled-3-1000rps.json
Overview
The file **`result-api-scaled-3-1000rps.json`** is a structured JSON report containing detailed performance testing results for an API under a load of 1000 requests per second (RPS). It captures a comprehensive set of metrics, thresholds, and runtime states collected during the test execution, focusing primarily on HTTP request timings, success/failure rates, throughput, and virtual user (VU) statistics.
This file serves as a snapshot output from a load testing framework (e.g., [k6](https://k6.io/)) that measures and analyzes the behavior of an API under heavy concurrent usage. The data provided helps developers, testers, and system analysts understand the system's responsiveness, stability, and capacity to handle the specified workload.
File Structure and Key Sections
The JSON report is organized into the following top-level keys:
root_group: Metadata about the root grouping of tests or checks.
options: Configuration options used for summarizing and presenting the test results.
state: Runtime environment information and test duration.
metrics: Detailed performance metrics and counters collected during the test.
Detailed Explanation of Sections
1. root_group
{
"path": "",
"id": "d41d8cd98f00b204e9800998ecf8427e",
"groups": [],
"checks": [],
"name": ""
}
Purpose: Represents the top-level grouping of test scenarios or logical test sets.
Fields:
path: Path or label for this group; empty here indicating root.id: Unique identifier (MD5 hash) for this group.groups: Nested sub-groups (empty).checks: Assertions or checks performed (empty).name: Name of the group (empty).
*Usage:* This section is a placeholder for hierarchical organization of tests but contains no detailed groups or checks in this file.
2. options
{
"summaryTrendStats": ["avg", "min", "med", "max", "p(90)", "p(95)", "p(99)", "count"],
"summaryTimeUnit": "",
"noColor": false
}
Purpose: Configuration guiding how summary statistics are computed and presented.
Fields:
summaryTrendStats: List of statistical measures included in trend summaries:avg: Average valuemin: Minimum valuemed: Median valuemax: Maximum valuep(90),p(95),p(99): 90th, 95th, and 99th percentilescount: Number of samples
summaryTimeUnit: Unit of time for metrics (empty here, likely milliseconds by default)noColor: Boolean flag, if true disables colored output for CLI (false here)
*Usage:* Defines how the metrics are summarized and reported, useful for interpretation of numerical values.
3. state
{
"isStdOutTTY": true,
"isStdErrTTY": true,
"testRunDurationMs": 300311.555708
}
Purpose: Captures runtime environment properties and test execution duration.
Fields:
isStdOutTTY: Boolean indicating if standard output is a TTY terminal.isStdErrTTY: Boolean indicating if standard error is a TTY terminal.testRunDurationMs: Duration of the test run in milliseconds (~300 seconds or 5 minutes).
*Usage:* Provides contextual info about how the test was run and its length.
4. metrics
This is the most critical and detailed section, containing various performance measurements collected during the test.
Each metric is a key-value pair where the key is the metric name (sometimes with tags), and the value is an object describing the metric type, nature, values, and thresholds.
Metric Types
rate: A rate measurement, e.g., failure rate.
trend: Time-based statistics showing distribution and percentiles.
counter: Counting occurrences or totals.
gauge: Instantaneous measurement with min/max/values.
Representative Metrics with Explanation
Metric Name | Type | Description | Notable Fields |
|---|---|---|---|
`http_req_failed{scenario:rps}` | rate | Failure rate of HTTP requests in the RPS scenario | `rate`, `passes`, `fails`, `thresholds` |
`http_req_duration{scenario:rps}` | trend | Distribution of HTTP request durations in the RPS scenario | `avg`, `min`, `med`, `max`, `p(90)`, `p(95)`, `p(99)`, `count`, `thresholds` |
`http_reqs` | counter | Total HTTP requests made | `count`, `rate` |
`vus` | gauge | Number of virtual users active | `value`, `min`, `max` |
`iteration_duration` | trend | Duration of iterations (single test scenario iteration duration) | Various percentiles and count |
`http_req_connecting` | trend | Time spent connecting | Percentiles and average |
`http_req_tls_handshaking` | trend | Time spent in TLS handshake | Percentiles and average |
`dropped_iterations` | counter | Number of iterations dropped due to errors or limits | `count`, `rate` |
`data_sent` | counter | Amount of data sent over network | `count` (bytes), `rate` |
`data_received` | counter | Amount of data received over network | `count` (bytes), `rate` |
Important Implementation Details and Algorithms
Threshold Checks: Several metrics include threshold conditions, e.g.,
"rate<0.01"or"p(95) < 800". These indicate pass/fail criteria for the test, automatically marking metrics as OK or failed.Percentile Calculations: Metrics include percentile calculations (p90, p95, p99) to show response time distribution tails, critical for performance analysis.
Scenario Tagging: Some metrics contain tags like
{scenario:rps}or{status:200}, enabling filtering results by scenario or response status.Trend Metrics: Trend metrics provide statistics over time intervals, revealing how performance evolves during the test.
Usage Examples
While this file is a data report rather than executable code, it is used as follows:
Performance Analysis: Load into a visualization tool or parse programmatically to evaluate API responsiveness and failure behavior under heavy load.
Threshold Validation: Automated CI/CD pipelines can parse this report to verify if performance thresholds are met.
Historical Comparison: Comparing multiple such JSON reports over time aids in spotting regressions or improvements.
*Example:* An engineer might extract the 95th percentile (`p(95)`) of `http_req_duration{scenario:rps}` to check if response times exceed the SLA of 800 ms, which in this file is marked as failed (`ok: false`).
Interaction With Other System Components
This file is generated by a load testing tool during test execution. It interacts upstream with the API under test (sending requests, measuring responses).
It serves downstream as input to:
Reporting tools that create human-readable summary reports or dashboards.
Alerting systems that trigger notifications if thresholds are breached.
Performance regression tests comparing current vs. baseline results.
The file typically integrates into a performance testing pipeline involving:
Test scenario definition (scripts)
Test execution with load tool producing this JSON output
Post-processing and reporting
Feedback loop to developers and testers
Visual Diagram: Flowchart of Main Data Elements and Relationships
flowchart TD
A[Performance Test Execution]
B[Metrics Collection]
C[root_group Metadata]
D[Options Configuration]
E[State Info]
F[Metrics Data]
G[Rate Metrics]
H[Trend Metrics]
I[Counter Metrics]
J[Gauge Metrics]
K[Threshold Checks]
A --> B
B --> C
B --> D
B --> E
B --> F
F --> G
F --> H
F --> I
F --> J
G --> K
H --> K
Explanation:
The test execution collects various data.
The root group, options, and state provide structure and config context.
Metrics are categorized into rates, trends, counters, and gauges.
Threshold checks are applied mainly on rate and trend metrics to evaluate pass/fail.
Summary
The **`result-api-scaled-3-1000rps.json`** file is a detailed performance test results report representing HTTP request metrics collected during a high-load scenario of 1000 requests per second. It enables stakeholders to:
Understand API performance distributions and bottlenecks
Validate compliance with performance thresholds
Analyze failure rates and request timing components
Track virtual user concurrency and iteration behavior
This file is crucial for performance engineers and QA teams to ensure the API meets expected service levels under heavy load conditions.