Menu

Post image 1
Post image 2
Post image 3
1 / 3
0

Don’t Charge Your Users Twice: Understanding Idempotency

DEV Community·Jane·21 days ago
#iUYDoduo
Reading 0:00
15s threshold

If you’ve ever been in a situation where you paid for pizza online, mustered the courage to begin and complete that transaction and accidentally said “you too” in response to “enjoy your meal. It’ll soon arrive” then you know that the only thing worse than the embarrassment from that conversation is realising that the pizza you ordered for say, $20 (great economy) has ensured you get charged $40 or worse $60. You know what’s worse than that still? Now you have to call the same person and complain about being triple-charged. You may be amused now as you sit comfortably indoors with your home-cooked meal, but it is an occurrence that may make you lay curses on the poor franchise when, in fact, you may have to shift your blame to the backend developers responsible for the feature. Idempotency is an interesting concept. It is based on the fact that acting many times provides the same result as doing it just once.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.

Read More