Skip to content

Releases

Settlement Lab v0.2.0

Choose a tag to compare

@NachoEstevo NachoEstevo released this 19 Nov 22:29

What happens to a payment when the primary dies after it has answered the client? Settlement Lab v0.2.0 starts a PostgreSQL 18.7 primary and a physical standby in an isolated Docker Compose project. Two independent Java workers submit real settlement commands. An external client records receipts, interrupts streaming, fences the primary and promotes the standby. It compares each acknowledged or unresolved command with the new primary before any case command is retried.

Replication Confirmed business commands present before retry, per trial First fresh settlement ACK, median [observed range]
Asynchronous 5 of 6 8.903 s [8.785–8.941]
Synchronous 5 of 5 7.765 s [7.622–8.086]

The table covers three trials per mode on one Windows Docker Desktop host. Time starts at the request to kill the old primary. A second connection checked the receipt for the new settlement. Promotion and route switching are controlled by the lab. In async mode the missing ACK belonged to a 7-unit settlement issued after the replication stream was cut. In sync mode the primary waited for the absent standby and never acknowledged that settlement. The independent client recorded two unresolved case commands in each trial; one was present after promotion and the other was absent. All replays produced one financial effect per command. The promoted primary operated alone.

Download settlement-lab-0.2.0.zip, extract it, and run the following from the extracted application directory with Java 21, Python 3 and Docker Compose available.

python failover/run.py --mode both --repetitions 3 --out my-evidence
python failover/verify.py my-evidence

The CSV and failover-v02-evidence.zip contain the six Windows trials behind the table. failover-evidence-windows.zip packages the same 51 files under a descriptive name. failover-evidence-linux-ci.zip contains six separate trials from Linux CI. Extract one evidence ZIP and pass its failover-evidence directory to the same verifier. SHA256SUMS covers all downloads. Measurements and environment · Linux failover run

Settlement Lab v0.1.0

Choose a tag to compare

@NachoEstevo NachoEstevo released this 19 Nov 21:46

The three participants have 60 SIM units between them and owe 300 around a ring. Use demo selection to see the FIFO policy stop at the first obligation and the multilateral policy settle the ring. A second fixture shows the heuristic selecting 4 units when the optimum is 5.

Download and extract settlement-lab-0.1.0.zip. The bundled launchers need Java 21. From the extracted directory, run ./bin/settlement-lab demo selection on Linux or .\bin\settlement-lab.bat demo selection on Windows.

For the concurrent experiment, run docker compose up -d --wait in that directory and pass pg race cancel-first or pg race settle-first --drop-reply to the launcher. A separate PostgreSQL connection observes the waiting writer before the winner commits. The second command recovers the original receipt after the reply is withheld. The recovery test uses a single PostgreSQL primary and its retained volume.

The attached economic report records eight ticks for each workload, including payments still waiting at the cutoff. Reproduce it with benchmark economic 20261119 32. The real-time capacity benchmark has separate measurements and hardware details. Results and environment

The ZIP is the artifact exercised by the Windows and Linux package jobs. SHA256SUMS covers both downloads. Distribution checks · Settlement checks