The problem
A school platform in production bills tuition through Multicaixa references. When a payment is not recognised, a family that has paid shows up as owing.
My job is to keep payments right, the platform up and its security in line with the data it holds, without stopping the service.
The approach
- 01
Reconciliation that reads every charge
The reconciliation job walks every page of the gateway's listing, with two guards: it detects repeated pages and has a maximum page count. If the response format changes, it logs the reason and stops, instead of finishing with an incomplete read.
- 02
Retrying when the number is already used
When the gateway rejects a transaction number as already used, the system moves to the next one and tries again, up to 15 times, logging each rejection. No one has to repeat the request by hand.
- 03
Hosting and backups
Containers with versioned images, controlled releases and backups with tested restores: a backup only counts if it can be restored.
- 04
Final approval
Everything comes in through a pull request, and I approve it. I check the tests and the automated rules, what happens if the change fails in production, and how to roll it back.