Special considerations for APKACIF exits written in COBOL

The ARSSPVIN sample APKACIF input exit is written as a COBOL main program. In order to prevent the Language Environment from creating and destroying the COBOL runtime environment each time ARSSPVIN is called, a CEEUOPT CSECT must be assembled and link-edited with the COBOL object code. Constructing a CEEUOPT CSECT is documented in z/OS Language Environment Customization SA22-7564. A sample CEEUOPT CSECT is included in data set CEE.SCEESAMP(CEEUOPT). You can use this sample as a model, but you must be sure that the following option is specified:
RTEREUS=(ON)
IBM also recommends that the ALL31(ON) option be specified, but this is not required.
In addition, you must be sure that the resulting module is link-edited as NOT RE-ENTRANT and NOT REUSABLE. This is required to allow the local variables in the COBOL exit code to retain their values across multiple invocations. The following is a sample CEEUOPT CSECT.
CEEUOPT CSECT ,
CEEUOPT AMODE ANY
CEEUOPT RMODE ANY

        CEEXOPT
              ABPERC=(NONE),                                        +
              ABTERMENC=(ABEND),                                    +
              AIXBLD=(OFF),                                         +
              ALL31=(ON),                                           +
              ANYHEAP=(16K, 8K, ANYWHERE, FREE)                     +
              BELOWHEAP=(8K, 4K, FREE),                             +
              CBLOPTS=(ON),                                         +
              CBLPSHPOP=(ON),                                       +
              CBLQDA=(OFF),                                         +
              CEEDUMP=(60,SYSOUT=*,FREE=END,SPIN=UNALLOC),          +
              CHECK=(ON),                                           +
              COUNTRY=(US),                                         +
              DEBUG=(OFF),                                          +
              DEPTHCONDLMT=(10),                                    +
              DYNDUMP=(*USERID,NODYNAMIC,TDUMP),                    +
              ENVAR=(''),                                           +
              ERRCOUNT=(0),                                         +
              ERRUNIT=(6),                                          +
              FILEHIST=(ON),                                        +
              FILETAG=(NOATOCVT,NOAUTOTAG),                         +
              HEAP=(32K,32K,ANYWHERE,KEEP,8K,4K),                   +
              HEAPCHK=(OFF,1,0,0,0),                                +
              HEAPPOOLS=(OFF,8,10,32,10,128,10,156,10,1024,10,2048, +
              10,0,10,0,10,0,10,0,10,0,10,0,10),                    +
              INFOMSGFILTER=(OFF,,,,),                              +
              INQPCOPN=(ON),                                        +
              INTERRUPT=(OFF),                                      +
              LIBSTACK=(4K,4K,FREE),                                +
              MSGFILE=(SYSOUT,FBA,121,0,NOENQ),                     +
              MSGQ=(15),                                            +
              NATLANG=(ENU),                                        +
              NOAUTOTASK=,                                          +
              NOTEST=(ALL,*,PROMPT,INSPPREF),                       +
              NOUSRHDLR=(''),                                       +
              OCSTATUS=(ON),                                        +
              PC=(OFF),                                             +
              PLITASKCOUNT=(20),                                    +
              POSIX=(OFF),                                          +
              PROFILE=(OFF,''),                                     +
              PRTUNIT=(6),                                          +
              PUNUNIT=(7),                                          +
              RDRUNIT=(5),                                          +
              RECPAD=(OFF),                                         +
              RPTOPTS=(OFF),                                        +
              RPTSTG=(OFF),                                         +
              RTEREUS=(ON),                                         +
              SIMVRD=(OFF),                                         +
              STACK=(128K,128K,ANYWHERE,KEEP,512K,128K),            +
              STORAGE=(NONE,NONE,NONE,OK),                          +
              TERMTHDACT=(TRACE,,96),                               +
              THREADHEAP=(4K,4K,ANYWHERE,KEEP),                     +
              THREADSTACK=(OFF,4K,4K,ANYWHERE,KEEP,128K,128K),      +
              TRACE=(OFF,4KDUMP,LE=0),                              +
              TRAP=(ON,SPIE),                                       +
              UPSI=(00000000),                                      +
              VCTRSAVE=(OFF),                                       +
              XPLINK=(OFF),                                         +
              XUFLOW=(AUTO)                                         +

        END		,