Providing concurrent access to a set of shared resources is disclosed. An
attempt is made, at the time it becomes necessary to use each resource
required to perform an operation or set of operations, to lock the
resource. For each attempt to lock a required resource, information
associated with the attempt to lock the resource is stored. In the event
a lock cannot be obtained with respect to a required resource, a renewed
attempt to perform the operation or set of operations is initiated. At
the outset of the renewed attempt, an attempt is made to lock all of the
required resources that were locked or attempted to be lock during the
previous attempt to perform the operation or set of operations.