Skip to content

SO Apps 7: Idempotency Info Sources

July 23, 2016

Back in the 20th century, before the broad use of Service Oriented Apps, many software systems depended upon distributed transactions using the 2-phase commit to ensure data was properly obtained from, and saved into, databases.  Many software systems did not use messaging back then. Nowadays Service Oriented Apps often use messaging, plus also steer away from using distributed transactions since the various databases used are spread far and wide — from the data center to various clouds.  Widely distributed data makes the resource locking required for distributed transactions problematic in various ways, plus distributed transactions tend to produce high latency times.

Learning how to design and develop Service Oriented systems using messaging and avoiding distributed transactions requires some new perspectives, knowledge, and skills.  One part of the new knowledge required is how to create idempotent designs that facilitate “at least once” delivery messages.  This kind of delivery is common with most messaging technologies today.  “At least once” means that a given message may be delivered once, or twice, or more often.  The software must be able to effectively deal with multiple deliveries, and the duplicate data within the multiply delivered messages.  And this requires idempotency.

Here are a few articles I found useful concerning idempotency and related issues:

Messaging:  At-least-once-delivery, by Jonathan Oliver, April 2010.

Idempotency Patterns by Jonathan Oliver, April 2010.  This is a really useful article and widely cited.

Ditching 2-phased commits, by Jimmy Bogard, May 2013.  A good overview of problems with 2-phased commits and alternatives.

(Un)reliability in Messaging:  idempotency and deduplication by Jimmy Bogard, June 2013.  This shows a couple useful techniques with code snippets.

Life Beyond Distributed Transactions, Pat Helland, 2007?  Pat worked at and it is interesting to read about his perspective at this time.

I hope you find this information as useful as I did!

George Stevens

Creative Commons License

dotnetsilverlightprism blog by George Stevens is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License. Based on a work at

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: