× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Jai,
my commnts inline, marked by <D*B> </D*B>

Given the following ILE program calling scenario, is this an accurate
version of how commitment control will behave?

pgmA actgrp(*new)

monitor;

calls pgmB actgrp(*caller) // both running in *NEW now (along
with all other downstream calls)

on-error;

rolbk(e) or exec sql rollback (same results either way you specify
rollback)

endmon;



*NEW is the commitment control atomic boundary.
*******************
<D*B>correct</D*B>
********************

In this scenario, the pgmB makes calls to other *caller pgms with RLA files
under commitment control as well as SQL tables under commitment control.

When pgmA is called, the commitment boundary starts for *NEW.

*********************
<D*B>Only SQL starts commit by automatic - if the first update/insert is
made by RLA it will fail</D*B>
*********************
Any sql stored procedures that are issuing inserts/updates/deletes that

********************
<D*B>out of my head SQL programms are running in *CALLER and it will work as
expected</D*B>
********************
contain WITH UR (meaning, use this lock level within a commitment control
boundary) are in play.
*******************
<D*B>The commit master - in your example pgmA is the one and only
responsable for starting commit, setting the lock level and issuing commit
or roll back. </D*B>
********************

Any *caller pgms with COMMITMENT CONTROL (cobol) or COMMIT (RPG) that are
defined for a file, can issue writes/updates/deletes to be considered for
CC within this call scope of *NEW.

*******************
<D*B>correct</D*B>
********************

IF there is a critical error, the monitor in pgmA catches it and the
rollback occurs - everything is rolled back, pgm ends as well as the *NEW
actgrp commitment control boundary.

*******************
<D*B>correct</D*B>
********************

If pgmA finishes successfully, a commit does not even have to be specified,
as *NEW defines the commitment boundary.

*******************
<D*B>Good practice would be to do the commit in the commit master. I've
never tryed the implicit version. It might work, RCLACTGRP sends e commit
(very starnge in my opinion), ENDJOB sends a Rollback.</D*B>
********************

When pgmA ends, so does the *NEW actgrp boundary (as well as the commitment
control boundary). - all i/o's are committed.

*******************
<D*B>If someone ends the job, before it comes to its end a rollback would
occur.</D*B>
********************

Some additional comments:
- don't use Commiscope *JOB - never ever. It's a showstopper for using the
power of commoitment controll for all future.
- dont start with a commit! With ACTGRP *NEW it doesn't make any sense.
Unknown aborted transactions have to be started with ROLLBACK.


D*B



tia



jay



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.