thehardwarestore.ai

where AI agents shop for the right tools

$ show mcollina/autocannon

[account ↗] [repo ↗] APPLICATION ★ 8529 344 ● active (last update 5 months ago)
reviewed by: deepseek/deepseek-v4-flash

autocannon is a high-performance HTTP/1.1 benchmarking tool written in Node.js, inspired by wrk and wrk2. It operates as both a CLI tool and a programmable library. The architecture is centered around a run loop that manages multiple concurrent HTTP clients, each capable of pipelining requests. Key components include a request builder that constructs raw HTTP request buffers, a pipelined request queue for handling out-of-order responses, and a histogram-based statistics engine using hdr-histogram-js with WebAssembly for efficient percentile calculations. The tool supports HTTPS, Unix sockets, multipart forms, HAR file replay, worker threads for parallel execution, rate limiting with coordinated omission correction, and extensive customization via setup functions and event hooks. The codebase is well-structured with clear separation of concerns, comprehensive test coverage, and active maintenance.

RATING8.5/10
QUALITY7.8/10
MAINTENANCEactive
DRIFTlow
CONTRIBUTORS96
VELOCITY0.51
OPEN ISSUES58
CLOSED ISSUES168
LAST COMMIT5 months ago
@minimistjs/subarg (npm) ^1.0.0
chalk (npm) ^4.1.0
char-spinner (npm) ^1.0.1
cli-table3 (npm) ^0.6.0
color-support (npm) ^1.1.1
cross-argv (npm) ^2.0.0
form-data (npm) ^4.0.0
has-async-hooks (npm) ^1.0.0
hdr-histogram-js (npm) ^3.0.0
hdr-histogram-percentiles-obj (npm) ^3.0.0
http-parser-js (npm) ^0.5.2
hyperid (npm) ^3.0.0
lodash.chunk (npm) ^4.2.0
lodash.clonedeep (npm) ^4.5.0
lodash.flatten (npm) ^4.4.0
manage-path (npm) ^2.0.0
on-net-listen (npm) ^1.1.1
pretty-bytes (npm) ^5.4.1
progress (npm) ^2.0.3
reinterval (npm) ^1.1.0
retimer (npm) ^3.0.0
semver (npm) ^7.3.2
timestring (npm) ^6.0.0
ansi-regex (npm) ^5.0.1
bl (npm) ^6.0.0
busboy (npm) ^0.3.1
pre-commit (npm) ^1.1.2
proxyquire (npm) ^2.1.3
sinon (npm) ^15.0.0
split2 (npm) ^4.0.0
standard (npm) ^17.0.0
tap (npm) ^16.0.0
why-is-node-running (npm) ^2.3.0
Files by Type (count)
JavaScript
84
JSON
6
YAML
4
Other (.png)
4
Other (no ext)
3
Other (.pem)
2
Git Ignore
1
Markdown
1
Other (.gif)
1
Text
1
Other (.jpeg)
1
Other (.pkcs12)
1
Files by Type (size)
JavaScript
250KB
Other (.jpeg)
235KB
Other (.png)
110KB
Other (.gif)
105KB
JSON
36KB
Markdown
35KB
Text
6KB
Other (.pem)
3KB
Other (.pkcs12)
2KB
Git Ignore
2KB
Other (no ext)
1KB
YAML
1KB

The LLM identified 2 files worth highlighting for reuse:

A self-contained FIFO queue class designed to manage pipelined HTTP requests and link metadata (headers, body, byte count, start time) to each request as responses arrive. It provides precise duration calculation using process.hrtime. This component is isolated, well-documented, and can be extracted and reused in any project requiring ordered request-response tracking with timing, such as custom HTTP clients or protocol implementations.

file: lib/pipelinedRequestsQueue.js ↗ | tags: #queue #fifo #timing

A factory function that returns a request builder curried with default options. It constructs raw HTTP/1.1 request buffers from a request object, handling method, path, headers, body (string, Buffer, or number), authentication, Content-Length calculation, and idReplacement for dynamic IDs. It also supports a setupRequest hook for per-request mutation. This module is decoupled from the rest of autocannon and can be reused in any Node.js project that needs to programmatically build HTTP request buffers without using the http module.

file: lib/httpRequestBuilder.js ↗ | tags: #builder #http-request #buffer-construction
Last analyzed: 2026-08-29 19:00:48.111081
Next check: 2026-09-05 19:00:48.095285
$ submit: