mirror of
https://github.com/prosolis/gogobee.git
synced 2026-07-15 00:32:40 +00:00
Every caller of Credit/Debit today is a Matrix message, and a Matrix message arrives once. The Pete games escrow will claim buy-ins over a poll loop, where a claim that succeeds but whose ack is lost gets retried — and the player pays twice. euro_transactions had no external id and no unique constraint to stop it. Adds external_id + a partial unique index, and CreditIdem/DebitIdem: balance mutation and transaction log in one tx, keyed by the escrow GUID. A replay is a no-op that still reports ok; a rejection leaves no trace, so the same GUID can be retried once the player is good for it.
4.4 KiB
4.4 KiB