Results
What we broke, and what held.
Each area is a set of automated scenarios. Every result is checked against what actually landed in the database, not against what the till reported.
Healthy till: scan and sale speed
5 of 5 passedNormal trading with the store database up. The baseline every failure scenario is compared against.
- Scans are answered by the store database
- A cash sale is recorded exactly once, with stock moved once
- A new till fills its own offline product cache without help
- Average scan response
- 14 ms
- Cash sale finalised in
- 50 ms
Store server unreachable
9 of 9 passedThe database service is stopped, or the network cable is pulled, while the till is trading.
- Scanning continues from the till's own cache — no scan is lost
- Sales are queued on the till and the cashier always gets an answer
- When the server returns, every queued sale is sent exactly once, with nobody touching the till
- Slowest scan once the till knows it is offline
- 11 ms
- Back online after the server returns (worst)
- 8.2 s
- Queued sales sent after the server returns (worst)
- 6.1 s
Database busy: tables locked by reports and backups
14 of 14 passedThe server is up but a sales or product table is locked — by a long report, a nightly backup, or another program.
- Scans are never lost while a table is locked
- The cashier gets an answer to every sale before the till gives up
- Every sale lands exactly once after the lock is released; nothing is parked as failed
- Slowest scan while a table is locked
- 5.0 s
- Slowest sale answer while a table is locked
- 10.0 s
Connection lost in the middle of a sale
41 of 41 passedThe link to the database drops at every step of recording a sale — before a statement runs, and after it ran but before the reply arrived.
- A write whose reply was lost is never blindly sent twice
- Every sale ends up recorded exactly once, complete, with stock moved once
- A second press of Finalise on the same sale is harmless
- Slowest sale answer with the link cut mid-sale
- 12.0 s
- Recovered sales recorded after the link returns (worst)
- 10.1 s
Till screen under faults
6 of 6 passedThe real till screen in a browser while the database is slow, busy or gone, and after a crash.
- Scans fired while an earlier scan is slow are not lost
- The online / offline badge changes by itself
- A paid sale interrupted by a crash is recorded once on the next start
- Badge shows offline after the server drops
- 27 ms
- Badge back online after the server returns
- 13.6 s
Account, lay-by, voucher and points sales refuse cleanly offline
20 of 20 passedSales that need the store server's agreement are never queued — they are refused clearly when it cannot be reached.
- Refused while the server is down, drops just before Finalise, or a table is locked
- Nothing is saved and nothing is queued when refused
- They go through normally when everything is reachable
Loyalty server outage after the sale
4 of 4 passedThe loyalty server drops after a voucher or points sale was approved.
- The voucher or points commit is kept and sent once the loyalty server returns
- A long outage never uses up the retries
- A refusal is kept and shown, never silently dropped
Two tills, one database, faults hitting both
4 of 4 passedTwo tills, each with its own queue, selling at the same time while the server goes down, the link flaps, or a table is locked.
- Both queue and replay at the same time; nothing is lost or doubled
- Stock moves by the combined quantity of both tills
- Slowest sale answer with both tills selling
- 10.0 s
- Both queues sent after the server returns (worst)
- 10.2 s
Item search with the server down or busy
4 of 4 passedThe item search popup by department, word and exact code.
- Every search mode answers from the till's cache when the server is down
- A locked product table never holds up a scan
- Word search answered offline
- 440 ms
Offline reconcile: sell offline, restore, totals match to the cent
1 of 1 passedA trading session with the store server unreachable in the middle of it. Sales before, during and after the outage are compared with what the server holds once the link is back.
- Transaction count at the server equals the count at the till
- Rand totals of sales, lines and payments match to the cent
- Nothing missing, nothing duplicated, stock moved once
- The queue is sent by itself — nobody presses anything
- Sales rung up while offline
- 20
- Sales in the session
- 26
- Sales at the server after sync
- 26
- Rands taken at the till
- R 1 881.42
- Rands at the server
- R 1 881.42
- Missing
- 0
- Duplicated
- 0
- Sync time after the link returned
- 3.1 s