benchmark

command
v0.8.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2025 License: Unlicense Imports: 19 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

Nostr Relay Benchmark

Usage

# Build
docker build -f cmd/benchmark/Dockerfile -t relay-benchmark .

# Run all relays
docker run --rm relay-benchmark all

# Run specific relay
docker run --rm relay-benchmark orly
docker run --rm relay-benchmark strfry 1000 50

Parameters

docker run --rm relay-benchmark [relay] [events] [queries]

relay:   all | orly | khatru-badger | khatru-sqlite | strfry | nostr-rs | relayer
events:  number of events (default: 10000)
queries: number of queries (default: 100)

Results

Date: August 17, 2025
Test: 5,000 events, 100 queries
Docker: golang:1.24, rust:1.82

Relay Version Events/sec Queries/sec
ORLY 0.8.0 8,762 3-7*
Khatru-Badger git HEAD 7,859 3-7*
Khatru-SQLite git HEAD 206 3-4*
Strfry git HEAD 1,856 13*
nostr-rs-relay 0.9.0 2,976 4-5*
Relayer git HEAD 1,452 6-7*

⚠️ Known Limitations:

  • Query rates are NOT representative of production performance
  • Uses sequential queries on single connection (not concurrent)
  • Tests on fresh database without optimized indexes
  • Small dataset (5K events vs millions in production)
  • Event publishing rates ARE accurate and representative

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL