Adds a locking system on accounting to prevent concurrent modifications of the same data