Rule Builder > Working with Repositories and Locking > Locking Packages

Locking is only effective on repositories that have already been stored once as files or in a Relational Database Management System (RDBMS). If the repository has been newly created and not saved there is no concurrent modification issue.

When you open an existing project in a repository, you need to lock the packages that contain the elements you want to modify. You can lock both top-level packages and nested packages. When a package is locked, you can modify elements in this package directly or elements in nested packages indirectly. To be able to add a subpackage, you must have its parent package locked.

Locked packages appear with a modified icon:

Project, Library, and BOM are subtypes of a package. The corresponding icon is modified if they are locked.

To lock a package:

If you open a project from a repository, other users will be able to open and modify the packages it contains, except for the ones that you have already locked. Another user can lock a package not locked by you. When you lock a package, the lock is recursive and all subpackages (or nested packages) are locked too. This means that a user:

Figure 7.2 shows the Project Explorer of two users A and B.

images/locking_example.png

Figure 7.2    Project Explorer with Locking Enabled

User A (on the left) and User B (on the right) have opened the "monkey" project of the same repository. User A has locked the project and has added a new package called "RulePackage" to it. User A has not yet saved the modifications. User B has locked the "monkey" package. User B has also locked the library "monkey library" but has then released the lock.

In the User A Project Explorer, the images/wasbusy.gif icon shows that the "monkey library" is no longer locked, but may have been modified. Therefore, if User A wants to lock "monkey library", the affected element must be reloaded. The images/busy.gif icon on the "monkey" package shows that this package is still locked by another user. When the user positions the mouse cursor on the icon, the tooltip displayed gives information about the owner and the date of the lock.

See Also

Opening an Existing Repository | Reopening an Existing Repository | Locking Projects | Releasing Locks | Locking and Concurrent Repository Access


Customer Support | Copyright © 1987-2004 ILOG S.A. All rights reserved. Legal terms. PREVIOUS   NEXT