call CBL_SRV_SERVICE_FLAGS_SET using by value service-flags-mask
by value service-flags
returning status-code
Bits 0 and 1 are treated as a bit pair and only relate to container-managed services. If neither bit is set, at service termination the run-time system will commit transactional resources if the service completes successfully, otherwise it will rollback transactional resources.
Attempting to set both bits 0 and 1 will be treated as an error; attempting to set either bit 0 or bit 1 by an application-managed service will also be treated as an error.
copy "cblproto.cpy".
...
78 78-SERVICE-FLAG-COMMIT value h"00000001".
78 78-SERVICE-FLAG-ROLLBACK value h"00000002".
78 78-SERVICE-FLAG-DIRTY-CONTAINER value h"80000000".
01 service-flags pic x(4) comp-5.
01 service-flags-mask pic x(4) comp-5.
...
*>
*> Clear the "rollback" flag.
*> Set the "commit" and "dirty container" flags
*>
compute service-flags-mask = 78-SERVICE-FLAG-COMMIT b-or
78-SERVICE-FLAG-ROLLBACK b-or
78-SERVICE-FLAG-DIRTY-CONTAINER
compute service-flags = 78-SERVICE-FLAG-COMMIT b-or
78-SERVICE-FLAG-DIRTY-CONTAINER
call "CBL_SRV_SERVICE_FLAGS_SET" using
by value service-flags-mask
by value service-flags
...