Application Locks Table - lucienlazar/plsql-application-locking GitHub Wiki

The application locks table is the core of the framework and stores the logical locks set by the client. A lock is identified uniquely by a lock id, is set on a certain object, by a certain process run id and can have three modes: shared, write exclusive or full exclusive.

Structure of the application locks table

The three types of locks handled by the framework are:

Shared (S)

used for reading;

shared locks can be acquired when other shared or write exclusive locks already exist on the resource;

cannot be acquired when a full exclusive lock already exists on the resource.

Write exclusive (WX)

used for writing;

write exclusive locks can be acquired when shared locks already exist on the resource;

cannot be acquired when other write exclusive or full exclusive lock already exist on the resource.

Full exclusive (FX)

strictly exclusive;

can be acquired only when no other locks exist on the resource.