Acquiring shared locks for stable objects incurs much less overhead, at the expense of extra cost when acquiring an exclusive lock. However, as stable objects are updated infrequently, exclusive locks are not often required.
A stable object is deemed locked at a node level as well as individually by process, and the lock at node level remains in place as a dormant lock even when processes no longer have the object locked. Instead of being released immediately the object is unlocked, a node lock remains in place until required to be released.
You can use the read-only
The constants provided by the
Constant | Character Value | Description |
---|---|---|
Kind_Local | '01' | Applies to stable objects and represents a shared, transient duration lock that has an associated node lock (Kind_Node) entry in the database server lock tables. There is no individual lock entry for the process in the database server lock tables (unless the process is a server application). |
Kind_Node | '02' | Applies to stable objects and represents a shared, transient duration lock that may be held by one or more processes on the node associated with the node lock. The associated background process of the node is used as the locking process. A node lock is released when an exclusive lock request is received or the object is removed from the node’s cache and there are no processes on the associated node that have the object locked with local locks. |
Kind Normal | '00' | Represents a lock held by a process. It is released when the process unlocks the object. |
The JADE Monitor displays node locks as shared locks, transaction duration, node kind, locked by the background process of the associated node.