A run unit is kept open (extended) when a dialog passes control to another dialog, user program, or application function by using an INVOKE, LINK, TRANSFER, or EXECUTE NEXT FUNCTION command.
A run unit is extended when control passes to any one of the following:
If a run unit is not already open and the LINK command's USING RECORDS list includes SUBSCHEMA-CONTROL, CA ADS opens and extends a run unit. If the run unit is already open, the run unit is extended.
A usage mode is considered more restrictive than another usage mode if either of its two components is more restrictive.
The following table shows the relative restrictiveness of usage modes.
|
Restrictiveness |
Usage mode |
Qualifier |
|---|---|---|
|
Most restrictive |
Update |
Exclusive |
|
|
|
Protected |
|
|
Retrieval |
Shared |
|
Least restrictive |
Noready |
|
Considerations
The following considerations apply to extended run units:
The LINK command does not automatically write a checkpoint to the CA IDMS/DB journal file. This allows a lower level dialog to check for errors and issue a ROLLBACK command if necessary. In this case, the entire extended run unit is rolled back.
If a COMMIT command is included in either dialog, the dialog is rolled back only to the COMMIT checkpoint. In this case, the entire extended run unit is not rolled back.
It is possible that the extended run unit will no longer be extended, if:
and
A run unit that is no longer extended can have a serious impact on handling a potential ROLLBACK or abend. If the run unit is no longer extended, then recovery can be incomplete and can disrupt the integrity of the database. If such a change to the subschema occurs, we recommend comparing the original application run unit structure to the modified application run unit structure. For this comparison, use, for example, ADS TRACE=CTL or Journal Reports.
We recommend not to use the subschema FORCE option for ADS applications with extended run units. Change the dialog code instead.
Several problems can occur if you use the subschema FORCE option for ADS applications with extended run units. For example, if the dialog that needs a new area is the recipient of an extended run unit, the FORCE area is not READIED.
Note: For more information on the limitations of using the FORCE option with ADS dialogs, see the Area Statement section (in the Subschema Statements chapter) in the CA IDMS Database Administration Guide.
It may be more efficient to remove subschema BIND and FINISH activities from the user program and allow the extended run unit to handle these functions. In this case, the issuing dialog must pass SUBSCHEMA-CONTROL to the program. Subschema records passed to the program must be bound only if the user program provides its own subschema record buffers. When control returns to CA ADS, the runtime system automatically rebinds the record buffers.
If a dialog links to a lower level dialog after beginning an SQL transaction (where the lower level dialog also issues SQL commands), the developer must either:
Choice one results in two units of recoverable work; choice two results in a single recoverable unit of work. When neither one or two are done, the SQL request of the lower level dialog fails, because its RCM information is not found in the active AM.
|
Copyright © 2014 CA.
All rights reserved.
|
|