Ask HN: Preventing Starbucks card type hacks

3 points by tmaly ↗ HN
What strategies have you employed when creating a system to prevent race conditions like happened to Starbucks where people are able add money to their cards?

2 comments

[ 2.5 ms ] story [ 15.9 ms ] thread
Seems like a job for a mutex! Though I'll admit I haven't actually employed strategies against race conditions in any kind of web context...