Seventh International Database Engineering and Applications Symposium (IDEAS'03)
An Empirical Study of Commutativity in Application Code
Hong Kong, SAR
July 16-July 18
ISBN: 0-7695-1981-4
A typical object database manages concurrency control by instance locking, based on the identification of instance operations as "read" or "write". An alternative theory shows that additional concurrency can be obtained based on operation commutativity. Under commutativity theory, activities can be allowed concurrently as long as they commute, that is, the effect is the same in either order. In this paper, we study an extensive commercial application from a telecommunications domain, and determine how much concurrency is actually present for commutativity theory to use. Our study extends to identify not only the operations that commute, but the reasons for their commutativity as well. We separated the commutative operations into three categories: those that commute because both are read operations, those that commute because different fields are accessed, and those that commute for semantic reasons. By doing this in our analysis we were able to show a comparison in concurrency potential between commutative locking and the two other common locking protocols in existence: instance locking and attribute locking.