results

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package results carries the committed benchmark measurements, so anything that shows them — pigfox.com's /demos/fix-lab among them — reads this exact file rather than a retyped copy of its numbers.

cmd/bench writes one raw file per run into results/raw; cmd/summarize builds summary.json and SUMMARY.md from those files and nothing else. CI rebuilds the summary and fails on any difference, so no figure here is edited by hand.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SummaryJSON

func SummaryJSON() []byte

SummaryJSON returns the committed file's bytes.

Types

type Machine

type Machine struct {
	CPUModel string `json:"cpu_model"`
	CPUs     int    `json:"cpus"`
	MemTotal string `json:"mem_total"`
	Kernel   string `json:"kernel"`
	GoArch   string `json:"goarch"`
}

Machine is where a run happened, as the bench read it from the kernel.

type Run

type Run struct {
	Name string `json:"name"`
	// Sessions is how many FIX sessions sent orders at once, and Window how
	// many unacknowledged orders each may have in flight.
	Sessions int `json:"sessions"`
	Window   int `json:"window"`
	// Orders is how many measured orders were sent (warm-up excluded);
	// Acked how many came back as ExecutionReport New, Rejected how many as
	// Rejected (expected 0), Fills how many trade reports the sessions got.
	Orders   int64 `json:"orders"`
	Acked    int64 `json:"acked"`
	Rejected int64 `json:"rejected"`
	Fills    int64 `json:"fills"`
	// Seconds is from the first measured send to the last measured ack.
	Seconds         float64 `json:"seconds"`
	OrdersPerSecond float64 `json:"orders_per_second"`
	// Ack latency: from just before the client hands a NewOrderSingle to the
	// engine to the moment the engine hands the client the ExecutionReport
	// New for it. Exact nearest-rank percentiles over every measured order.
	AckP50Micros int64  `json:"ack_p50_us"`
	AckP90Micros int64  `json:"ack_p90_us"`
	AckP99Micros int64  `json:"ack_p99_us"`
	AckMaxMicros int64  `json:"ack_max_us"`
	Warmup       int64  `json:"warmup_orders"`
	Transport    string `json:"transport"`
	StartedUTC   string `json:"started_utc"`
	RawFile      string `json:"raw_file"`
}

Run is one benchmark run.

type Summary

type Summary struct {
	Machine   Machine `json:"machine"`
	GoVersion string  `json:"go_version"`
	Engine    string  `json:"engine"`
	Date      string  `json:"date"`
	// Setup and Notes are the one hand-written part, from results/notes.json:
	// how the runs were set up, and what limits the figures.
	Setup string   `json:"setup"`
	Notes []string `json:"notes"`
	Runs  []Run    `json:"runs"`
}

Summary is the whole committed file.

func Load

func Load() (Summary, error)

Load returns the committed summary.

Jump to

Keyboard shortcuts

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