Wednesday, December 29, 2010

An Scaling pattern: Life beyond Distributed Transactions: an Apostate’s Opinion

The paper “Life beyond Distributed Transactions: an Apostate’s Opinion” provides an inserting a scaling pattern to cope without transactions for very large scale.

The idea can be described using three things: entities, activities, and using workflows instead of transactions.
  • entity is a single collection of data that lives within a single scope of serializability (e.g. cluster). Each entity has a unique key, and transactions cannot expand multiple entities.
  • Activity is a relationship between two entities (holds all state about such a relationship).
  • Finally, the key idea is that entities cope by not doing transactions with each other, but handling the uncertainty rise out of lack of transactions through a workflow. 
  • The author makes an interesting observation that normal world does not have transactions, but cope with uncertainties through time limits, compensations, cancellations etc., or in other words cope through a workflow. So he argues that activities should be carried out with tentative message, confirmation or cancellation model.
So does that scale? Yes, handling stabilizability within one entity is very much possible, and rest is data partition, which is well understood. Only key decider is that can we model uncertainties that arise from lack of transactions through workflows. My gut feeling is most of the time we can, but there certainly are exceptions.

No comments: