A proxy lock is a global lock used within a data sharing group to represent a lock on all the records within a page of a shared area. Proxy locks are held by members of a data sharing group and not by individual transactions.
An Additional Hierarchy Level
Proxy locks represent an additional level in the locking hierarchy used by CA IDMS to control access to data.
Normally CA IDMS uses a two-level locking hierarchy: area and record. Before placing a lock on a record, a transaction must place a lock on the area in which the record resides. Depending on the mode of the area lock, it may be possible to avoid placing locks on individual records within the area.
For shared areas, the locking hierarchy expands to three levels: area, proxy, and record. Before a lock is placed on a record in a shared area, a lock must be held on a proxy that represents the record's page and before this can be done, a lock must be held on the area in which the record resides.
Proxy Lock Modes
A proxy can be locked in one of two modes: Share or Exclusive. At least a share lock must be held on a proxy before a transaction can place a share or null (notify) lock on a record represented by the proxy. Similarly, an exclusive proxy lock must be held before a transaction can place an exclusive lock on a record represented by the proxy.
Managing Proxy Locks
An exclusive proxy lock held by one member does not prohibit access by another member. Instead the purpose of proxy locks is to detect inter-CV contention for resources and to eliminate the use of global record locks where possible. As long as all members holding a lock on a proxy hold it in share mode, there is no contention for resources on the page and no need to globally lock individual records on that page. However, if at least two members hold a lock on a proxy and at least one of those is an exclusive lock, then there is possible contention for individual records, necessitating the use of global record locks to control access to individual records.
The acquisition and management of proxy locks is done automatically by the CA IDMS lock manager. Application programs do not need to explicitly acquire or manage proxy locks. However, database administrators should be aware of their existence and their impact on recovery and resource utilization.
|
Copyright © 2014 CA.
All rights reserved.
|
|