680 Integrating IBM Tivoli Workload Scheduler with Tivoli Products
*
MOVE 'S' TO EPLM-ACTION-FLAG
MOVE +17 TO EPLM-REQUEST
MOVE +4 TO EPLM-SEVERITY
CALL 'J06YTBL' USING EPL-JOB-SCAN-ERRORS
EPLM-DATA
MOVE '101 TWS WILL WAIT FOR SPECIAL RESOURCE.'
TO EPLC-ERROR-MESSAGE
MOVE 4 TO EPLC-SEVERITY
PERFORM Z999-SET-ERROR
STRING '102 TWS RESNAME = "' DELIMITED BY SIZE
DATA-SET-NAME DELIMITED BY SPACES
'"' DELIMITED BY SIZE
INTO EPLC-ERROR-MESSAGE
MOVE 0 TO EPLC-SEVERITY
PERFORM Z999-SET-ERROR.
*
CALL-DD-ENTRY-EXIT.
EXIT.
COPY CERR.
JOB/SCAN TWS interface module TWSSPRES
TWSSPRES is invoked by TWSSTD1 to look up Special Resource names in the
TWS for z/OS data base (see Example C-2).
Example: C-2 JOB/SCAN interface module to extract Special Resource names
TWSSPRES CSECT
TWSSPRES AMODE 24
SAVE (14,12),,'TWSSPRES &SYSDATE &SYSTIME DSSI'
LR R12,R15 ESTABLISH BASE REGISTER
USING TWSSPRES,R12 TELL ASSEMBLER
LA R14,SAVEAREA CHAIN SAVE AREAS
ST R14,8(,R13) MINE INTO MVS
ST R13,4(,R14) MVS INTO MINE
LR R13,R14 MINE IS NOW CURRENT
*
* get parms
*
L R2,0(R1) ADDRESS OF SUBSYSTEM FIRST PARM
MVC SUBSYS,0(R2) GET SUBSYSTEM NAME
L R2,4(R1) RESOURCE NAME SECOND PARM
MVC LUNAME,0(R2) SAVE IT
L R2,8(R1) RESOURCE NAME SECOND PARM
Appendix C. JOB/SCAN examples 681
MVC TRGTNAME,0(R2) SAVE IT
LOAD EPLOC=EQQYCOM
ST R0,EQQYADDR
*
* init eqqycom
*
MVC ACTION,=CL8'INIT ' INDICATE INIT DESIRED.
MVC RESOURCE(4),SUBSYS
MVC NAMELIST(8),=CL8' '
CLI LUNAME,C' '
BNH NOLU
MVC NAMELIST(8),=CL8'LUNAME'
LA R2,LUNAME
ST R2,VALULIST
NOLU DS 0F
LA R1,PARMLIST SET UP PARM ADDRESS FOR EQQYCOM.
L R15,EQQYADDR
BALR R14,R15
LTR R15,R15 ANY PROBLEMS?
BNZ RC20 CONTINUE
*
* list special resource
*
MVC ACTION,=CL8'LIST ' INDICATE LIST DESIRED.
MVC RESOURCE,=CL8'SRCOM ' INDICATE RESOURCE NAME.
MVC NAMELIST(8),=CL8'RESNAME ' RESOURCE NAME
LA R2,TRGTNAME GET TARGET NAME
ST R2,VALULIST SAVE THE NAME ADDRESS
LA R1,PARMLIST SET UP PARM ADDRESS FOR EQQYCOM.
L R15,EQQYADDR
BALR R14,R15
C R15,RETCODE
ST R15,SAVERC
BNE RC24
*
* terminate eqqycom
*
MVC ACTION,=CL8'TERM ' INDICATE TERMINATION DESIRED.
LA R1,PARMLIST SET UP PARM ADDRESS FOR EQQYCOM.
L R15,EQQYADDR
BALR R14,R15
DELETE EPLOC=EQQYCOM
L R15,SAVERC GET LIST RETURN CODE
B RETURN
RC24 DS 0H
LA R15,24
B RETURN
RC20 DS 0H
LA R15,20
682 Integrating IBM Tivoli Workload Scheduler with Tivoli Products
RETURN DS 0H
L R13,4(,R13) RESTORE MVS SAVE AREA
RETURN (14,12),RC=(15) RETURN TO MVS
*
PARMLIST DC A(ACTION) ACTION CODE
DC A(RESOURCE) RESOURCE CODE
DC A(DATAPTR) DATA AREA ADDRESS
DC A(NAMELIST) ARGUMENT NAME LIST
DC A(VALULIST) ARGUMENT VALUE LIST
DC A(COMBLOCK) COMMUNICATION BLOCK
LISTEN DC A(RETCODE) RETURN CODE
*
ACTION DC CL8' ' * ACTION CODE
RESOURCE DC CL8' ' * RESOURCE NAME
DATAPTR DC F'0' * DATAAREA POINTER
NAMELIST DC CL80' ' * 10 ARGUMENT NAMES
VALULIST DC 10F'0' * ADDRESSES OF 10 VALUES
COMBLOCK DC F'0' * COM BLOCK POINTER
RETCODE DC F'0' * RETURN CODE
SUBSYS DC CL4' '
LUNAME DC CL17' '
TRGTNAME DC CL44' '
SAVEAREA DC 18F'0'
saverc DC F'0'
EQQYCOM DC CL8'EQQYCOM '
EQQYADDR DC A(*-*)
LTORG
YREGS
END

Get Integrating IBM Tivoli Workload Scheduler with Tivoli Products now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.