Starting Nostr Relay Benchmark
Data Directory: /tmp/benchmark_relayer-basic_8
Events: 10000, Workers: 8, Duration: 1m0s
20250912223509638362 INF /tmp/benchmark_relayer-basic_8: All 0 tables opened in 0s
/go/pkg/mod/github.com/dgraph-io/badger/v4@v4.8.0/levels.go:161 /build/pkg/database/logger.go:57
20250912223509638864 INF /tmp/benchmark_relayer-basic_8: Discard stats nextEmptySlot: 0
/go/pkg/mod/github.com/dgraph-io/badger/v4@v4.8.0/discard.go:55 /build/pkg/database/logger.go:57
20250912223509638903 INF /tmp/benchmark_relayer-basic_8: Set nextTxnTs to 0
/go/pkg/mod/github.com/dgraph-io/badger/v4@v4.8.0/db.go:358 /build/pkg/database/logger.go:57
20250912223509639558 INF (*types.Uint32)(0xc00570005c)({
 value: (uint32) 1
})
 /build/pkg/database/migrations.go:65
20250912223509639620 INF migrating to version 1... /build/pkg/database/migrations.go:79

=== Starting test round 1/2 ===

=== Peak Throughput Test ===
Events saved: 10000/10000 (100.0%)
Duration: 659.848301ms
Events/sec: 15155.00
Avg latency: 513.243µs
P90 latency: 706.89µs
P95 latency: 792.685µs
P99 latency: 1.089215ms
Bottom 10% Avg latency: 864.746µs

=== Burst Pattern Test ===
Burst completed: 1000 events in 142.551144ms
Burst completed: 1000 events in 137.426595ms
Burst completed: 1000 events in 139.51501ms
Burst completed: 1000 events in 143.683041ms
Burst completed: 1000 events in 136.500167ms
Burst completed: 1000 events in 139.573844ms
Burst completed: 1000 events in 145.873173ms
Burst completed: 1000 events in 144.256594ms
Burst completed: 1000 events in 157.89329ms
Burst completed: 1000 events in 153.882313ms
Burst test completed: 10000 events in 6.47066659s
Events/sec: 1545.44

=== Mixed Read/Write Test ===
Pre-populating database for read tests...
Mixed test completed: 5000 writes, 5000 reads in 37.483034098s
Combined ops/sec: 266.79

Pausing 10s before next round...

=== Starting test round 2/2 ===

=== Peak Throughput Test ===
Events saved: 10000/10000 (100.0%)
Duration: 701.479526ms
Events/sec: 14255.58
Avg latency: 544.692µs
P90 latency: 742.997µs
P95 latency: 845.975µs
P99 latency: 1.147624ms
Bottom 10% Avg latency: 913.45µs

=== Burst Pattern Test ===
Burst completed: 1000 events in 143.063212ms
Burst completed: 1000 events in 139.422008ms
Burst completed: 1000 events in 138.184516ms
Burst completed: 1000 events in 148.207616ms
Burst completed: 1000 events in 137.663883ms
Burst completed: 1000 events in 141.607643ms
Burst completed: 1000 events in 143.668551ms
Burst completed: 1000 events in 140.467359ms
Burst completed: 1000 events in 139.860509ms
Burst completed: 1000 events in 138.328306ms
Burst test completed: 10000 events in 6.43971118s
Events/sec: 1552.86

=== Mixed Read/Write Test ===
Pre-populating database for read tests...
Mixed test completed: 5000 writes, 4870 reads in 1m0.034216467s
Combined ops/sec: 164.41

================================================================================
BENCHMARK REPORT
================================================================================

Test: Peak Throughput
Duration: 659.848301ms
Total Events: 10000
Events/sec: 15155.00
Success Rate: 100.0%
Concurrent Workers: 8
Memory Used: 153 MB
Avg Latency: 513.243µs
P90 Latency: 706.89µs
P95 Latency: 792.685µs
P99 Latency: 1.089215ms
Bottom 10% Avg Latency: 864.746µs
----------------------------------------

Test: Burst Pattern
Duration: 6.47066659s
Total Events: 10000
Events/sec: 1545.44
Success Rate: 100.0%
Concurrent Workers: 8
Memory Used: 206 MB
Avg Latency: 273.645µs
P90 Latency: 407.483µs
P95 Latency: 498.989µs
P99 Latency: 772.406µs
Bottom 10% Avg Latency: 574.801µs
----------------------------------------

Test: Mixed Read/Write
Duration: 37.483034098s
Total Events: 10000
Events/sec: 266.79
Success Rate: 100.0%
Concurrent Workers: 8
Memory Used: 163 MB
Avg Latency: 9.873363ms
P90 Latency: 21.643466ms
P95 Latency: 22.924497ms
P99 Latency: 24.961324ms
Bottom 10% Avg Latency: 23.201171ms
----------------------------------------

Test: Peak Throughput
Duration: 701.479526ms
Total Events: 10000
Events/sec: 14255.58
Success Rate: 100.0%
Concurrent Workers: 8
Memory Used: 153 MB
Avg Latency: 544.692µs
P90 Latency: 742.997µs
P95 Latency: 845.975µs
P99 Latency: 1.147624ms
Bottom 10% Avg Latency: 913.45µs
----------------------------------------

Test: Burst Pattern
Duration: 6.43971118s
Total Events: 10000
Events/sec: 1552.86
Success Rate: 100.0%
Concurrent Workers: 8
Memory Used: 204 MB
Avg Latency: 266.006µs
P90 Latency: 402.683µs
P95 Latency: 491.253µs
P99 Latency: 715.735µs
Bottom 10% Avg Latency: 553.762µs
----------------------------------------

Test: Mixed Read/Write
Duration: 1m0.034216467s
Total Events: 9870
Events/sec: 164.41
Success Rate: 98.7%
Concurrent Workers: 8
Memory Used: 184 MB
Avg Latency: 19.308183ms
P90 Latency: 42.766459ms
P95 Latency: 45.372157ms
P99 Latency: 49.993951ms
Bottom 10% Avg Latency: 46.189525ms
----------------------------------------

Report saved to: /tmp/benchmark_relayer-basic_8/benchmark_report.txt
AsciiDoc report saved to: /tmp/benchmark_relayer-basic_8/benchmark_report.adoc
20250912223751453794 INF /tmp/benchmark_relayer-basic_8: Lifetime L0 stalled for: 0s
/go/pkg/mod/github.com/dgraph-io/badger/v4@v4.8.0/db.go:536 /build/pkg/database/logger.go:57
20250912223752488197 INF /tmp/benchmark_relayer-basic_8: 
Level 0 [ ]: NumTables: 00. Size: 0 B of 0 B. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 64 MiB
Level 1 [ ]: NumTables: 00. Size: 0 B of 10 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 2.0 MiB
Level 2 [ ]: NumTables: 00. Size: 0 B of 10 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 2.0 MiB
Level 3 [ ]: NumTables: 00. Size: 0 B of 10 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 2.0 MiB
Level 4 [ ]: NumTables: 00. Size: 0 B of 10 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 2.0 MiB
Level 5 [B]: NumTables: 00. Size: 0 B of 10 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 2.0 MiB
Level 6 [ ]: NumTables: 02. Size: 41 MiB of 41 MiB. Score: 0.00->0.00 StaleData: 0 B Target FileSize: 4.0 MiB
Level Done
/go/pkg/mod/github.com/dgraph-io/badger/v4@v4.8.0/db.go:615 /build/pkg/database/logger.go:57
20250912223752491495 INF /tmp/benchmark_relayer-basic_8: database closed /build/pkg/database/database.go:134

RELAY_NAME: relayer-basic
RELAY_URL: ws://relayer-basic:7447
TEST_TIMESTAMP: 2025-09-12T22:37:52+00:00
BENCHMARK_CONFIG:
  Events: 10000
  Workers: 8
  Duration: 60s
