Patent ID: 8639677

Claim:
A computer-readable storage medium embodying computer usable program code for maintaining an order of transactions replicated from a source database to a target database, comprising: computer usable program code for receiving, from said source database, a first transaction and a second transaction, wherein said first transaction was committed prior to said second transaction at said source database; computer usable program code for processing said first transaction using a first thread, wherein a first lockable object is locked once processing of said first transaction begins, and said first lockable object is unlocked once said first transaction is committed; computer usable program code for, prior to committing said second transaction at said target database, determining whether said first thread has committed said first transaction, based on whether a lock on said first lockable object can be obtained and further based on whether a shared lock on said first lockable object can be obtained; computer usable program code for, in response to determining that said first thread has not committed said first transaction, serially processing said first transaction and said second transaction using said first thread, whereby said second transaction is committed after said first transaction at said target database; and computer usable program code for, in response to determining that said first thread has committed said first transaction, processing said second transaction using a second thread that is distinct from said first thread.