Repository Object Locks
When you begin to edit an object, the Model repository locks the object so that other users cannot save changes to it. When you save the object, you retain the lock. When you close the object, the repository releases the lock.
Lock Management
The Model repository retains object locks if the Developer tool stops unexpectedly. When you connect to the Model repository again, you can view the objects that you have locked. You can continue to edit the objects, or you can unlock the objects.
You might want to unlock objects if the developer who locked the object is unavailable and another developer is assigned to develop the object. You view and unlock locked objects through the Locked Objects dialog box.
To view the Locked Objects dialog box, click File > Locked Objects.
The following image shows the Locked Objects dialog box:
You can unlock one or more objects in the Locked Objects dialog box. Select objects to unlock by performing one of the following actions:
- •Use the check box to select one or more objects.
- •Select one or more rows and click Check Selection to enable the check box for each object that you selected.
Then you can click Unlock to unlock all the selected objects.
Tip: If your work is interrupted, you can view the objects that you have locked to identify the objects you were working on.
Rules and Guidelines for Lock Management
Consider the following rules and guidelines when you manage object locks:
- •The Model repository does not lock the object when you open it. The Model repository locks the object only after you begin to edit it. For example, the Model repository locks a mapping when you insert a cursor in an editable field or connect mapping objects.
- •You can use more than one client tool to develop an object. For example, you can edit an object on one machine and then open the object on another machine and continue to edit it. When you return to the first machine, you must close the object editor and reopen it to regain the lock. The same principle applies when a user with administrative privileges unlocks an object that you had open.
- •If the Model Repository Service restarts while you have an object open for editing, you lose the lock on the object. Until you regain a lock on the object, another user can open and edit it. To regain a lock on the object, save changes to the object and close it, then reopen the object for editing.
- •When you delete a folder that contains objects, and you are not allowed to delete any one of the objects, then you cannot delete the folder. For example, if you cannot delete an object because you do not own the lock on the object, the object and the folder remain.
- •More than one developer can open and edit the contents of an SQL data service object at the same time.
For example, UserA can open and begin to edit an SQL data service, and then UserB can open and begin to edit the same object. If UserB saves and closes the object before UserA, the Model repository does not tell UserA of the potential conflict until UserA saves the object. In this case, UserA can save changes by saving the SQL data service with another name.
- •An administrator can revoke your write permission on an object you have locked, or reassign the lock to another user. In this case, you cannot edit or save the object. You can save the object with another name.