

Database Access Commands › Navigational DML › Suppression of Record Retrieval Locks
Suppression of Record Retrieval Locks
Specifications can be made during dialog compilation to indicate whether or not database record retrieval locks will be held for dialog run units. Retrieval dialogs that do not update the database and do not pass currencies to update dialogs can be selectively allowed to access database records without locking those records.
Selectively disabling retrieval locks for dialogs allows:
- Elimination of the overhead of maintaining retrieval locks. This decreases the amount of potential storage and CPU time used by dialogs at runtime.
- Reduction of the number of db-key deadlocks.
Disabling Record Retrieval Locks
To disable record retrieval locks, you must:
- Analyze the dialog in the context of the entire application to ensure that control and currencies are passed appropriately. A dialog with disabled retrieval locks can pass control and currencies only to a dialog or user program that does retrieval based on these currencies.
- Verify the status of the system retrieval locks. If the mandatory retrieval locks are on, disable the locks at system generation time by specifying RETRIEVAL NOLOCK in the system generation SYSTEM statement.
Note: For more information, see the CA IDMS System Generation Guide.
- Use the CA ADS dialog compiler or ADSOBCOM to disable retrieval locking for appropriate dialogs.
Considerations
- To safeguard the database in the absence of retrieval locks, an update user program will be aborted when:
- The program receives currencies from a retrieval dialog and attempts an update DML call.
- The program finishes the current run unit and binds another. The abend occurs when control is passed back to CA ADS.
- The update dialog abends if:
- A higher dialog in the application thread has the RETRIEVAL NOLOCK indicator set and system-wide RETRIEVAL NOLOCKS are specified.
- An update dialog or program is allowed to update the retrieval dialog's database records in the following cases:
- The dialog with retrieval locks turned off readies the area in UPDATE mode.
- The update dialog/program does not receive currencies when control passes to it.
Updates are allowed because the update dialog/program must ready the database in UPDATE mode and establish its own currency. The dialog/program will use record-locking mechanisms and will be assured of having the most up-to-date data.
The control command options that avoid passing currencies when control is passed are the TRANSFER command and the NOSAVE clause of the DISPLAY, INVOKE, and LINK commands.
More information:
CA ADS Application Compiler (ADSA)
Control Commands
Application and Dialog Utilities
Copyright © 2014 CA.
All rights reserved.
 
|
|